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

Home » Public Forums » archive » Re: array of structures with pointers
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: array of structures with pointers [message #84201 is a reply to message #84200] Mon, 06 May 2013 11:06 Go to previous message
Heinz Stege is currently offline  Heinz Stege
Messages: 189
Registered: January 2003
Senior Member
Hello Wayne,

you can do this:

IDL> st = {flux:ptr_new()} ;Create a structure with a pointer
IDL> st = replicate(st,20) ;I want a structure with 20 elements
IDL> st.flux=ptrarr(n_elements(st),/allocate) ;Allocate all pointers
IDL> help,st[0].flux
<Expression> POINTER = <PtrHeapVar1>
IDL> help,st[4].flux
<Expression> POINTER = <PtrHeapVar5>

Cheers, Heinz
[Message index]
 
Read Message
Read Message
Previous Topic: array of structures with pointers
Next Topic: Can you resize a (Windows) modal widget?

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

Current Time: Fri Oct 10 08:21:15 PDT 2025

Total time taken to generate the page: 1.11948 seconds