Thang Nguyen Posted February 2, 2008 Report Share Posted February 2, 2008 Hi, I have a callback VI which works with a communication activeX. The return data has one element with variant type. The display of variant element is:Value-> Array (Non Displayable). I want to get this data but I cannot. I did try to use Variant To Data VI or Variant to Flat String VI, but I still get nothing. Do you have any idea? Quote Link to comment
Yuri33 Posted February 2, 2008 Report Share Posted February 2, 2008 When you wired the activeX refnum to the Register Event Callback node, did you try and create a Callback VI by right-clicking the VI Ref input and selecting "Create Callback VI"? Usually, LV can analyze the activeX event callback prototype and automatically create a properly formatted event callback VI with an appropriate control for the event data labeled "Event Data." If LV is still creating the variant this way, then the callback data is more complex. You're best bet then is to find the documentation for the activeX object you are communicating with. That will show you what type of data the event returns, and then you can create an equivalent LV prototype to cast the event data (using Variant to Data or perhaps Typecast). Quote Link to comment
LAVA 1.0 Content Posted February 2, 2008 Report Share Posted February 2, 2008 When you are using the Variant to data function with array, you have to set the type terminal with an array too (not necessarily 1D array). For an array of different type, you can start converting it into array of variant. Then you should be able to see your data into the variant indicator. Quote Link to comment
Recommended Posts
Join the conversation
You can post now and register later. If you have an account, sign in now to post with your account.