There are two things I don't understand:
1) what is the <EW> tag doing there?
2) Why the GXML generated text is not self describing?
I need to store data in XML or GXML format wich includes the value of an enumerated selector ring.
If I use the flatten to XML function I get:
<Choice>CHB leads CHA</Choice>
<Choice>CHA leads CHB</Choice>
Obviously the enum data type is not part of the regular XML data types.
Still, I like that all the possible selector values are listed, plus the selection is listed: <Val>1</Val>.
The only thing I don't understand what is the <EW> tag doing there? What does it mean?
if I use the gxml_generator.vi I get this:
<Desired_Channel_order type='Enum U16' sel='CHB leads CHA'>1</Desired_Channel_order>
In this case when I parse the GXML text I need to know what selection was made when the GXML text was created.
If I somehow don't know that the selection was 'CHB leads CHA' not 'CHA leads CHB' the parser sends an error.
Anyone can suggest a workaround? I am not experienced with XML.
And thank you for your time and effort.
The <EW> and </EW> tags indicate the start and end of the enum type. Everything related to your enum will be contained between these two tags.
The gxml_generator VI is actually a customer submitted VI. You can find more information here: http://zone.ni.com/devzone/cda/epd/p/id/6330
If you have further questions regarding the gxml_generator VI, this VI is supported on this thread: http://forums.ni.com/t5/Components/Reference-Library-for-Converting-Between-LabVIEW-and-XML-Data/td-...
Hope this helps!
Thank you for your time and effort.
I am familiar with the information that is presented on the webpages you linked me to.
I found a solution to my problem.
I am replacing all enums in my code with text rings.
This seems much easier that writing VI's to handle the XML to enum conversion.