Has anyone had any experience using the Research Systems IDL ActiveX control (IDLDrawX3, comes with IDl 5.5) with LabVIEW?
I get a strange memory error when I try to call the SetNamedArray method in some circumstances. The error reads:
"Memory is locked. in my.vi"
From the IDL manual:
"SetNamedArray. This method creates a named IDL array with the specified data. The data pointer is shared with IDL and the EDE application. Thus, changes in either IDL or the EDE will be reflected in both."
Arguments:
StrName (String),
vData (Variant),
bDestroyOnFree (Boolean)
If I make an event driven VI with a 2D array control, a load button, an activeX container containing an (IDL) IDLDrawX3 control, and a stop but
ton. Then on the value changed event for the load button call the SetNamedArray method - everything works fine.
However, if I create a data driven VI that just wires the SetNamedArray method in sequence with everything else then I get the memory locked error.
From a VB application one would declare a global 2D array and then pass this to SetNamedArray once at the start of the program. All changes to the array in VB are reflected within IDL since they are sharing the same block of memory.
=> I'm not sure how to do this in LabVIEW since the concept of variables is different. If the control containing the 2D array is modified I need to call SetNamedArray again to update the variable in IDL, which defeats the whole purpose of share memory.
Any thoughts?
I think the memory problem might be a generic ActiveX error...?
Novak.