X
PrevPrev Go to previous topic
NextNext Go to next topic
Last Post 20 Apr 2004 02:48 PM by  anon
Change data in iTool at runtime
 1 Replies
Sort:
You are not authorized to post a reply.
Author Messages

anon



New Member


Posts:
New Member


--
20 Apr 2004 02:48 PM
    I'm developing an IDL application that needs to change the X, Y, and Z data in an iSurface or iContour. I can get the data vectors easily enough with SurfaceParameterSet = Self->GetByIdentifier('/Data Manager/Surface parameters') XData = SurfaceParameterSet->GetByName('X') But the XData object doesn't allow me to change its data. The line XData->SetData, *CoLatitude give an error message: Attempt to call undefined method: 'IDLITDATAIDLVECTOR::SETDATA'. What's the secret? How can I change the data in an iTool? Greg

    Deleted User



    New Member


    Posts:
    New Member


    --
    20 Apr 2004 02:48 PM
    Hi Greg, I tried to do a similar thing. Here is a piece of code that worked for me: ; get a reference to the itool oTool = oSystem->_GetCurrentTool() ; get ref to x data oDataX = otool->GETBYIDENTIFIER("/DATA MANAGER/PLOT PARAMETERS/X") status = oDataX->GetData( x, ident ) ; get ref to y data oDataY = otool->GETBYIDENTIFIER("/DATA MANAGER/PLOT PARAMETERS/Y") status = oDataY->GetData( y, ident ) xnew = 5+indgen(100) ynew = indgen(100)*0.1 status = oDataX->SetData( xnew, ident ) status = oDataY->SetData( ynew, ident ) Regards, Pepijn
    You are not authorized to post a reply.