Owning Palette: Variant VIs and Functions
Requires: Base Development System
Converts any LabVIEW data to variant data. You also can use this function to convert ActiveX data to variant data.
Add to the block diagram | Find on the palette |
anything is any LabVIEW data you want to convert. This parameter is polymorphic. | |
variant is the resulting variant data. |
If you use the To Variant and Variant to Data functions with LabVIEW classes consider the following caveat.
Variants do not recognize inheritance hierarchies. For example, if you have child data traveling on a parent class wire and you then wire the parent wire to a To Variant function, the variant recognizes only the parent data type. If you wire a child data type to the Variant to Data function to extract the child data, LabVIEW returns an error. You must wire the parent to the Variant to Data function. Then use the To More Specific function to retrieve the child class data.