[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: Obtaining variable names as strings





Martin Schultz wrote:
> 
> Ian Dean <ian.d.dean@baesystems.com> writes:
> 
> 1.) please don't use html mail in future posts.
> 
> 2.) i'm still not entirely sure what you want to do here, but from
> your description it sounds as if there are several things done in
> an unnecessarily complex way? Even if the include file is sacrosanct
> as you say (BTW: I would never accept such a statement), you could
> still treat it as a normal ASCII file and read in the variable definitions
> e.g. into structures like { varname:"Joe", value:"200" } or into
> two arrays: strarr() and values(). This would make searching and
> matching much easier.
> 
> 3.) but if you really need to include the include file as such,
> Reimar Bauer can probably tell you how to use the undocumented
> features of routine_name() to achieve what you want.
> 
> Martin
> 


Hi, Ian

in the past I have used some variables in the same way I think as
you like to do it now.

The following function founds defined variables without structures.
They are removed by some statements in the routine.

http://www.fz-juelich.de/icg/icg1/idl_icglib/idl_source/idl_html/dbase/download/variab.tar.gz

This function uses the internal routine routine_info. This is an
undocumented routine and it could 
be that it will be removed in future releases. 
Many routines e.g. Craigs restore or the read_ascii etc. are using some
features of this
routine.

I prefer myself reading variabels in structures mentioned by Martin see
point 2.



regards
Reimar




-- 
Reimar Bauer 

Institut fuer Stratosphaerische Chemie (ICG-1)
Forschungszentrum Juelich
email: R.Bauer@fz-juelich.de
http://www.fz-juelich.de/icg/icg1/
=============================================
a IDL library at ForschungsZentrum Jülich
http://www.fz-juelich.de/icg/icg1/idl_icglib/idl_lib_intro.html

http://www.fz-juelich.de/zb/text/publikation/juel3786.html