09-03-2013 01:16 PM
Wasn't as hard as I thought. I modified two VIs in GXML Search Parser to output the "remaining XML string" (which they already produced, just didn't bring it to a connector), and added a helper VI, gxml_AllowMissingTags, that checks if error 537525, Missing Opening Tag, is present, and if so, it clears the Error line and returns Booleans. I ended up returning both Tag Present (used in conjunction with a Conditional Tunnel to exclude the non-existent "Missing Data") and Tag Missing (wired to the While Loop's Stop Terminal). I realize I could do this with a single Boolean, particularly if I use a "Continue" instead of a "Stop" on my While loops, but I'm a Slave to Consistency ...
Anyway, in conjunction with my Action Engine described a few posts above, I'm now able to write XML files in an on-going, "piece-meal" fashion, including having multiple elements at the same hierarchical level with the same name, and using the above Search Parse function inside a While Loop with the remaining XML string in a Shift Register, guarded by AllowMissingTags, to get all of the XML data back.
What a joy to work with GXML! I'm happy to contribute my ideas, particularly if they show up as a revised VIPM Package (much easier to install, and VIPM is now part of LabVIEW 2013).
Bob Schor
09-04-2013 08:12 PM
Oops, made a stupid (but subtle!) mistake in my modified gxml_NameFilter. I was trying to remove name characters that were not alphanumeric, period, hyphen, or underscore. I'd replaced a "Match Pattern" function with the regular expression [^a-zA-Z0-9.-_], used to find the existence of an illegal character, with a "Search and Replace" VI (with Regular Expression turned on) using the same regular expression. However, these two VIs treat the period differently, as I found when the string "Date/Time" made it through without removing the slash, only to be "caught" with the slash as an illegal character.
I made two changes. First, I decided that instead of removing the slash, I'd replace it with hyphen (giving "Date-Time"). I also fixed the regular expression by putting the period as the last character (I'm not 100% why this works, but it does).
Here's the "better" Name Filter.
BS
09-17-2013 11:51 AM - edited 09-17-2013 11:57 AM
With the newly released GXML ver 1.4.1.6.(Sep 11, 2013), since GXML is required by the Structured Error Handler (SEH) and must be installed prior to installing SEH http://digital.ni.com/public.nsf/allkb/15A83EAE41E2F46F862579FE00388806.
If I want to upgrade GXML, because of the sequential install requirement, must I
09-17-2013 11:58 AM
I would try installing GXML before SEH. Here is the correct link to the Structured Error Handler:
http://zone.ni.com/devzone/cda/epd/p/id/6253
09-17-2013 12:14 PM
I cannot find the latest GXML Library (1.4.1.6). I asked VIPM to refresh its package base, and also looked through the LabVIEW Tools Network (which showed me 184 items, none of which seemed to be GXML, though I confess to not looking at every single one, but none started with "GXML" and none starting with "NI" or "National Instruments" were GXML.
I'd greatly appreciate help here ...
Bob Schor
09-18-2013 09:28 AM - edited 09-18-2013 09:29 AM
Bob,
GXML is available on the NI LabVIEW Tools Network repository which is automatically scanned by VIPM.
It is compatible with LabVIEW 2010 and later, so if your VIPM is set to an earlier version of LabVIEW, GXML will not show up in the list of available packages to install.
Also make sure you have the latest version of VIPM (version 2013) installed.
Searching the LabVIEW Tools Network website will not show GXML as we have not created an entry for GXML in that database so far, but it is available directly through VIPM.
09-18-2013 10:08 AM - edited 09-18-2013 10:08 AM
If that does not work there are links to the package from the GXML dev zone document.
http://zone.ni.com/devzone/cda/epd/p/id/6330
Under the "Downloads" section there is an "Install Toolkit" link that will automatically launch VIPM and install GXML and an "Alternative Download" link that will take you to the ftp site where you can download the package manually.
Regards,
Jeff Tipps
NI Systems Engineer
09-18-2013 12:51 PM
Thanks, Jeff. I installed it from the VIPC, and noticed it has "moved" from user.lib to vi.lib. Also, the GXML Palette that used to be in User Libraries is now gone. Has it appeared somewhere else? [I did notice a .mnu file flashing by during the installation, so I assume it is somewhere].
I've made a few minor tweaks to the previous set of GXML files (some of which have been described here). I'd like to write these up and present my ideas somewhere, possibly for inclusion in a future release. How would you suggest I do this? I'm thinking of a PDF file (possibly several pages long) discussing my ideas and how I've implemented them, and why, possibly along with "pictures of code" (e.g. pasted snippets).
Bob Schor
09-18-2013 01:22 PM
Bob,
The pallettes are now accessible from the "Addons" subpallette. I am the owner of GXML and would love to take a look at your suggestions. A pdf file would be fine please post that here. SE libraries are not updated on a regular development cycle like products are but they do get updated on an as-needed basis and I would definitely take your ideas into consideration.
Best Regards,
Jeff Tipps
NI Systems Engineer
09-19-2013 07:12 AM
Jeff,
Is there a changelog somewhere of what is different in the latest version?
Thanks,
Mike