george seifert Posted September 30, 2008 Report Share Posted September 30, 2008 I'm trying to figure out how to get the className of an IVI I/O control. See the enclosed picture that shows the variant value I get when I use a CTL property node to return the value. Download File:post-2786-1222711224.bmp The variant value shows the className that I'm trying to retrieve (in this case niDCPower). This className is what shows up if you right click on an IVI I/O control and then select Select IVI Class. I tried converting to an XML string, but that doesn't return the value I need. Any ideas on how to return this name? George Quote Link to comment
LAVA 1.0 Content Posted October 1, 2008 Report Share Posted October 1, 2008 QUOTE (george seifert @ Sep 29 2008, 08:06 PM) Any ideas on how to return this name?George What does http://forums.lavag.org/VariantProbe-file63.html' target="_blank">this tool tells you? Have you looked at the NI variant tools (vi.lib/Utility/VariantDataType)? The GetTypeInfo VI returns the type of the refnum to an IVI refnum. Ton Quote Link to comment
george seifert Posted October 1, 2008 Author Report Share Posted October 1, 2008 QUOTE (Ton @ Sep 30 2008, 07:11 AM) What does this tool tells you?Have you looked at the NI variant tools (vi.lib/Utility/VariantDataType)? The GetTypeInfo VI returns the type of the refnum to an IVI refnum. Ton Unfortunately I couldn't load the probe because I don't have OpenG. But I was able to navigate to the Refnum case in your browse variant VI and saw where you use the Variant to Data VI with a Generic type that feeds a property node that gets the ClassName. That's pretty much what I had tried before and didn't work. I've also tried all the NI Variant tools. I've inlcuded a quick and dirty VI in case someone has time to look at it. Forget about how I get the variant value (it simulates how I do it in my real VI). I generated the Variant value and then made it a control to make it easier to use. The VI wouldn't work if you don't have the PXI hardware (or have it simulated). It bugs me that I can see the className right there in the variant value control, but can't figure out how to extract it. Any ideas would be welcome. Download File:post-2786-1222782130.vi George 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.