Re: execute problem [message #7953] |
Thu, 30 January 1997 00:00 |
Phil Williams
Messages: 78 Registered: April 1996
|
Member |
|
|
R. Bauer wrote:
>
> Hi,
>
> here is an other problem
>
> we have idl versions 3.61 and 4.01.
>
> in idl 4.01 it's possible to execute a string with the length 625.
> idl 3.61 gave the error that's the string is too long.
>
> There is no way in our case to seperate the string, because it's a
> definition for a structure.
>
> Now the questions:
>
> where is the border for a string to execute by idl 4.01?
>
No idea there was even a border in 3.6.1!
> how could I solve the problem for idl 3.61?
One way that I could think of off the top of my head would be to
reference your structures via tag number instead of tag name. i.e.
structure.(0).(1).(10)
I'd imagine that there might be some overhead if you are using anonymous
strutures to determine the tag placement. Something like,
names = tag_names(structure)
index1 = where(names eq structure2)
names = tag_names(structure.(index))
index2 = where(names eq structure3)
etc.
ps = ').('
command = $
'print, structure.('+strtrim(index1,2)+ps+strtrim(index2,2)+ps+....
Hope this helps,
Phil
--
/*********************************************************** ********/
Phil Williams, Ph.D.
Research Instructor
Children's Hospital Medical Center "One man gathers what
Imaging Research Center another man spills..."
3333 Burnet Ave. -The Grateful Dead
Cincinnati, OH 45229
email: williams@irc.chmcc.org
URL: http://scuttle.chmcc.org/~williams/
/*********************************************************** ********/
|
|
|
Re: execute problem [message #7954 is a reply to message #7953] |
Thu, 30 January 1997 00:00  |
Phil Williams
Messages: 78 Registered: April 1996
|
Member |
|
|
There goes that damn SEND button again!
Phil Williams wrote:
>
> One way that I could think of off the top of my head would be to
> reference your structures via tag number instead of tag name. i.e.
>
> structure.(0).(1).(10)
>
> I'd imagine that there might be some overhead if you are using anonymous
> strutures to determine the tag placement. Something like,
>
You'll probably need quotes here. :)
> names = tag_names(structure)
> index1 = where(names eq 'structure2')
> names = tag_names(structure.(index))
> index2 = where(names eq 'structure3')
>
> etc.
>
> ps = ').('
> command = $
> 'print, structure.('+strtrim(index1,2)+ps+strtrim(index2,2)+ps+....
>
> Hope this helps,
> Phil
>
> --
> /*********************************************************** ********/
> Phil Williams, Ph.D.
> Research Instructor
> Children's Hospital Medical Center "One man gathers what
> Imaging Research Center another man spills..."
> 3333 Burnet Ave. -The Grateful Dead
> Cincinnati, OH 45229
> email: williams@irc.chmcc.org
> URL: http://scuttle.chmcc.org/~williams/
> /*********************************************************** ********/
--
/*********************************************************** ********/
Phil Williams, Ph.D.
Research Instructor
Children's Hospital Medical Center "One man gathers what
Imaging Research Center another man spills..."
3333 Burnet Ave. -The Grateful Dead
Cincinnati, OH 45229
email: williams@irc.chmcc.org
URL: http://scuttle.chmcc.org/~williams/
/*********************************************************** ********/
|
|
|