× The internal search function is temporarily non-functional. The current search engine is no longer viable and we are researching alternatives.
As a stop gap measure, we are using Google's custom search engine service.
If you know of an easy to use, open source, search engine ... please contact support@midrange.com.




On Fri, 7 Sep 2001, Tony Pack wrote:

> Hi all,
>       I think this can be done, but this is new to me.  I want to read a
> record from a file, get the value from a field, and then use that value's
> name as a field within the program.

You can't do that, sorry.   Here's a gross oversimplification of why:
The  variable's "name" is usually something symbolic that makes it easier
for you to write your program.   Once the program has been compiled, that
name is gone -- it's working with addresses in memory instead.

So, you can't use data in a file to give you a variable name -- At least
not directly.

> I am reading on ALLOC and DEALLOC, and it looks as if I can use the
> pointers to create a heap space and then set it's value via pointers.
> Has anyone got any examples of a similar task they would care to share?

I'm not quite sure what you're trying to do.  Are you just looking for
examples of how to use pointers?   Or are you actually looking for
something more specific?

Perhaps if I had an idea of what you need to accomplish and why, I might
be able to show you a technique that would help...   can you send more
information?

Thanks!



As an Amazon Associate we earn from qualifying purchases.

This thread ...

Follow-Ups:
Replies:

Follow On AppleNews
Return to Archive home page | Return to MIDRANGE.COM home page

This mailing list archive is Copyright 1997-2024 by midrange.com and David Gibbs as a compilation work. Use of the archive is restricted to research of a business or technical nature. Any other uses are prohibited. Full details are available on our policy page. If you have questions about this, please contact [javascript protected email address].

Operating expenses for this site are earned using the Amazon Associate program and Google Adsense.