comp.lang.idl-pvwave archive
Messages from Usenet group comp.lang.idl-pvwave, compiled by Paulo Penteado

Home » Public Forums » archive » Re: Is there any way to change the dimension of a field in a structure?
Show: Today's Messages :: Show Polls :: Message Navigator
E-mail to friend 
Return to the default flat view Create a new topic Submit Reply
Re: Is there any way to change the dimension of a field in a structure? [message #58153] Tue, 22 January 2008 04:21
David Fanning is currently offline  David Fanning
Messages: 11724
Registered: August 2001
Senior Member
Hongkai writes:

> However, the question is, if I only know the tag name of the field
> Dog, and I don't know the tag names of other fields in S, how can I
> change the dimension of Dog?

Make Dog a pointer. :-)

S = {Dog:Ptr_New(lindgen(3,112)), Cat:'cc', Horse:[1,2,4]}
*S.Dog = lindgen(3,118)

Cheers,

David
--
David Fanning, Ph.D.
Fanning Software Consulting, Inc.
Coyote's Guide to IDL Programming: http://www.dfanning.com/
Sepore ma de ni thui. ("Perhaps thou speakest truth.")
[Message index]
 
Read Message
Previous Topic: Is there any way to change the dimension of a field in a structure?
Next Topic: color shift between 2 contour plots?

-=] Back to Top [=-
[ Syndicate this forum (XML) ] [ RSS ] [ PDF ]

Current Time: Fri Nov 28 14:22:44 PST 2025

Total time taken to generate the page: 0.32267 seconds