Components

cancel
Showing results for 
Search instead for 
Did you mean: 

Reference Library for Converting Between LabVIEW and XML Data (GXML)

I did not think to use those since they seem like they were designed for Windows not RT.  Maybe you could consider leaving the dialog subvi's out for a cross platform version.

0 Kudos
Message 41 of 132
(9,435 Views)

They work fine in RT if you wire a file path to them.

 

Regards,

 

Jeff Tipps

S&V Systems Engineer

0 Kudos
Message 42 of 132
(9,433 Views)

Yes of course, but I find that it is better not to drag that stuff into an RT hierarchy.  Often I will get wierd project error popups related to the use of unsupported RT features for such things.

0 Kudos
Message 43 of 132
(9,431 Views)

 

Since I added the GXML vi's in an app, my built exe is giving me a runtime error (see attachment).  Also, if it makes a difference I moved the installation hierarchy to my own location outside of the LV folder but the app does run fine from the development environment.

 

Error.png

0 Kudos
Message 44 of 132
(9,402 Views)

Sachsm,

 

It looks like there are several components that your VI cannot find.  I recommend taking this question to the general LabVIEW forum.

 

Regards,

 

Jeff Tipps

S&V Systems Engineer

0 Kudos
Message 45 of 132
(9,397 Views)

I went ahead and changed the build options to include all library items and it produced a huge exe and also a dialog box asking me to save 2 vi's from the GXML directory.  After I saved these

2 files everythings started to work correctly and was even able to remove the previous build option and have normal sized exe's.  Maybe the thing to do before you use the GXML libraries in a build is to mass compile them on your development machine.

0 Kudos
Message 46 of 132
(9,393 Views)

Example where fast parser works correctly but recursive parser fails.  Any idea why?

0 Kudos
Message 47 of 132
(9,223 Views)

Hello sachsm,

 

If you throw the "Simple Error Handler.vi" onto the end of your program GXML is returning the error "XML Closing Tag </Workbook> not found"  Now in your XML string the closing tag </Workbook> is there but things do not line up.

 

First two open tags:

BrokenOpen.png

 

Last two close tags:

BrokenClosed.png

 

Notice how </Workbook> is preceeded by two whitespaces?  I know the XML specifications advise processors to ignore whitespaces but in order to enable the search algorithm without forcing you to define a unique name for every item (especially in arrays) I look for the matching closing tag name AND matching whitespace.  GXML usually handles all of this but in your case there is this dangling closing tag "</GXML_Root> that is located at the same heirarchy as the open tag <Workbook>.

 

By looking at the spacing between your first two open tags I suspect you deleted the open tag <GXML_Root> and moved the open tag <Workspace> to the left two spaces.  The easiest fix for your string is to also delete </GXML_Root> and move </Workbook> to the left two spaces.

 

The GXML_Root tags are optional but they exist for concatination purposes.  You can flatten GXML strings in two seperate processes and concatinate them together under one container called "GXML_Root".  If you are using concatination then you will need to leave those tags alone.

 

Regards,

 

Jeff Tipps

S&V Systems Engineer

0 Kudos
Message 48 of 132
(9,221 Views)

The problem is a bug in the gxml_ReadXMLfromFile.vi that does not work for XML files that lack a version header. (It will unintentionally strip off the first line <GXML_Root>)

Here is the corrected version.  Note the \? is needed in the regular expression

 

gxml_ReadXMLfromFile Bug Fix.png

0 Kudos
Message 49 of 132
(9,218 Views)

Why would the XML file have no version header?

 

Jeff

0 Kudos
Message 50 of 132
(9,214 Views)