LabVIEW

cancel
Showing results for 
Search instead for 
Did you mean: 

xml parser in LV2013

Hi,

 

I am using inbuilt XML parser in LabView (Load XML File.VI), to validate a XML file before it is processed.

To get the validation the XSD file name need to inserted in the actual XML file.

The system which we use do not insert the path of XSD file in the XML file and we can not modify the XML file

before feeding it in parser. So, is there a way to give the path of XSD file separately instead of mentioning it inside the XML file.

 

Your help is highly appreciated.

0 Kudos
Message 1 of 5
(2,938 Views)

@Ayum wrote:

Hi,

 

I am using inbuilt XML parser in LabView (Load XML File.VI), to validate a XML file before it is processed.

To get the validation the XSD file name need to inserted in the actual XML file.

The system which we use do not insert the path of XSD file in the XML file and we can not modify the XML file

before feeding it in parser. So, is there a way to give the path of XSD file separately instead of mentioning it inside the XML file.

 

Your help is highly appreciated.


Share the Code and Need little bit clarity on requirement

----------------------------------------------------------------------------------------------------------------
Palanivel Thiruvenkadam | பழனிவேல் திருவெங்கடம்
LabVIEW™ Champion |Certified LabVIEW™ Architect |Certified TestStand Developer

Kidlin's Law -If you can write the problem down clearly then the matter is half solved.
-----------------------------------------------------------------------------------------------------------------
0 Kudos
Message 2 of 5
(2,893 Views)

ok, please find the attached VI.

 

So my question, here is that to validate the XML file . one need to give “Always” to validate on load option in the the “Load XML.VI”.

The XML is validated with the help of its XSD file, which is mentioned at the top of XML file. This is a standard format. Am I correct ?

In our system the XML produced does not have information about the XSD file inside them. So, is there a way around through which I can separately provide the path of XSD file and get it verified without modifying my XML file.

 

Does it make sense to you. Please let me know if your require more clarification.

 

Thanks

0 Kudos
Message 3 of 5
(2,874 Views)

The "Load XML File" vi is ploymorphic. You can choose to load from a file, or from a string. If you load from a string, you can open your xml file beforehand, load into memory, and alter the first line to define the schema file.

 

 

Certified-LabVIEW-Architect_rgb.jpgCertified_TestStand_Architect_rgb.jpg


"I won't be wronged. I won't be insulted. I won't be laid a-hand on. I don't do these things to other people, and I require the same from them." John Bernard Books

0 Kudos
Message 4 of 5
(2,868 Views)

That is a good solution, but one of our objective is that the XML file given as input or as string should not be modified in any way. The XML file/ string shoudl go as it is into the parser. This is the last option which i will follow to verify but still looking if any other solution is available.

 

thanks for your reply..

0 Kudos
Message 5 of 5
(2,866 Views)