Welcome to http://labxml.sourceforge.net/

An XML-toolkit for Labview

Release notes

In version 1.0 of the libXML-toolkit libXML the "libXML Edit XML tree.vi", one of the most important vi's, had a few bugs:
-the replace function did not work at all
-the "add after node" function did only add after the last avaialble node

These bugs have been fixed in vs 1.2

We are still looking for people who did compile the libararies for MAC-OS, so we can include the compiled versions in the packages. Please inform me about your experience, using the package on a MAC.

License
-------
This work is under LGPL
(http://www.opensource.org/licenses/lgpl-license.php),
the GNOME libXML2 libraries are under MIT License
(http://www.opensource.org/licenses/mit-license.html)

Release notes

LibXML-toolkit is a platform-independent implementation of an XML interface for
Labview, a graphical programming language from National Instruments
(http://www.ni.com/labview/), contributed by Markus Lippitz.
It is a plug-in replacement for the MSXML-toolkit, but the Microsoft
ActiveX MSXML interface is replaced by libXML2, the XML library of
the GNOME project (http://xmlsoft.org/).
It is therefore platform independent. It only needs the libXML2 libraries and a wrapper library,
that can be compiled under many operating systems. Windows and Linux
libraries are supplied in this package, Mac should not be a problem to
recompile. (Please let me know if you do so, to include it in this
package.)
The MSXML toolkit stays available, but will not be supported or updated anymore.

Release notes

Version 1.5 is mainly a bug-fix. Some memory-leak problems have been solved. But the main fix concerns reading XML-files with comments. In former versions the read-in XML-tree became errornous when it contained more then one comment-line. This is fixed now.
VI's are still compiled for Labview 6.1 and use the MSXML-4.0 parser of MicroSoft

MSXML-toolkit Version 1.4
------------
-Feb, 10, 2004-
------------

Release notes

While version 1.3 has been een internal testversion version 1.4 is again available for the public.
Several minor bugs have been solved. The most important one being the memory leak in the "MSXML read XML tree.vi" . In the former releases this vi called a recursive vi. That vi has been replaced by "serial" vi which crawls down the XML-tree and gathers all elements in an array. The problem was that not all openend references to elements were closed afterwards. And in the recursive vi the references were lost. In the "serial" solution the not closed references are closed after all the elements are gathered. This should solve the problem of the memory leak. VI's are compiled for Labview 6.1 and use the MSXML-4.0 parser of MicroSoft

MSXML-toolkit Version 1.2
------------
-Dec, 17, 2002-
------------

Release notes

-In version 1.2 the following bug has been fixed:
Read XML-tree did not read empty elements.

-A feature has been added:
The get values.vi is an easy way to read values of elements and attributes by means of XPATH-queries.

---Intro---

The MSXML-toolkit is covered by the LGPL software license LGPL software license which means that you may use them in your commercial applications.

The MSXML-toolkit is a first step to a LabVIEW XML toolkit,
born out of a need to be able to use XML as a data format to save instrument control parameters as well as measurement data.
The toolkit supports the following functions:

---To use this package you need to have the MSXMLparser vs 4.0 installed---

The toolkit is based (for now) on the DOM-model (Document Object Model) and uses
the Microsoft XML Core Services (MSXML 4.0) ActiveX control, which is available at
Microsoft under web development-XML-MSXML 4.0 RTM;
see allso
whatsnew

If you want to join the developers group, or just have a question, suggestion, or remark, be free to fill out the
mail-form..
Of course you can also just surf through the
SourceForge LabXML project.

If you want to download these files immediately go to the
LabXML download area.
But please do not forget to install the the Microsoft XML Core Services (MSXML 4.0) ActiveX control from the
Microsoft site

The heart of the toolkit is the the control MSXML Element.ctl.
This cluster is, as an element in an 1D-array, the Labview-interface to the DOM-model.

Element contains:

Element-name: this is the tag name

Element-value: the strings in between the begin- and end-tag

Attributes: contains the attribute-names and -values (Often meta-data) of this element.

Structured: this boolean is set if there are subelements for this element;

Parent: Referrer to the parent-element of this element. Normally the Elemnt-cluster will be an element of an array. Parent is referring to the index of the parent-element

CDATA: Is set if Element-value contains "non-parsable-data"

The toplevel-VI's, which can easily be used in applications are:

MSXML Create New XML-file.vi

Creates a new XML-file with root-element name and without any subtags

MSXML Edit XML.vi

There are 3 edit modes:

Remove the node from the document

Insert the XML-tree into the document as a child of the selected node

Replace the selected node in the document by the XML-tree

Insert the XML-tree as a sibling of the selected node

MSXML Open XML-file.vi

Loads the XML-file as an XML-document into memory

MSXML Read XML-tree.vi

This is a recursive VI which reads the complete tree of SelectedNode belonging to the loaded XML-document and adds it to "XML-tree in" resulting isn "XML-tree out". SelectedNode could be the node found by the select node vi. The parent input should refer to the hierarchical parent in the XML-tree to which the tree of the selected node is added. The parent-input is 0 if "XML-tree in"is empty.
There will be no check whether the parentnr exists nor if this is the right position for the child to be added to the XML-tree.

MSXML Save XML.vi

Backup the old file and saves the document to file. The document will not be closed and references are still valid

MSXML Select nodes in document.vi

This Vi searches the XML Document with the querystring according tothe Xpath protocoll and returns the number (length) of the nodes found as well as the first Node found. If not found "not found"will be set true

MSXML Translate with XSLT.vi

Will use the XSL-file to generate a file from the XML-data, like an HTML-file.

MSXML Validate.vi

This VI will validate the XML-document when "Validate on Parse" is TRUE (MSXML Open XML-file.vi)

The example

To get the flavor of the possiblities, here is the frontpanel of the example included in the package:

At the moment we do not use CVS. I suppose, for a small group and a small package like this it will be suffucient to just mail the code to the administrator. The developers will know where to send their code. So if you want to contribute code, please join the project.
Please send your comments and/or requests to join the developers-group by the
mail-form.