LabVIEW

cancel
Showing results for 
Search instead for 
Did you mean: 

Obtain Array from an XML file with Multiple Arrays

Solved!
Go to solution

Hi,

So I have been struggling with this program I am making for the last few months but I am almost there. I have a program that creates multiple arrays and place them one after another in an xml file and each array has its own unique name. Now I would like to create a VI that takes this XML file and when the user inputs the specific array name they are looking for it goes into the xml file finds the entire array under that name and displays it in an output indictor to be viewed on the VI. Attached is a sample of my xml file and the VI that creates this xml file.

 

Thanks,

dlovell

0 Kudos
Message 1 of 7
(3,618 Views)
Solution
Accepted by topic author dlovell

Something like this should work for you.

 

 

Find Array_BD.png

=====================
LabVIEW 2012


0 Kudos
Message 2 of 7
(3,603 Views)

Here is a slightly different version. The one above reads from a file. This is how you would read from an already loaded XML string.

 

Find Array_BD.png

=====================
LabVIEW 2012


0 Kudos
Message 3 of 7
(3,599 Views)

@dlovell wrote:

Hi,

So I have been struggling with this program I am making for the last few months but I am almost there. I have a program that creates multiple arrays and place them one after another in an xml file and each array has its own unique name. Now I would like to create a VI that takes this XML file and when the user inputs the specific array name they are looking for it goes into the xml file finds the entire array under that name and displays it in an output indictor to be viewed on the VI. Attached is a sample of my xml file and the VI that creates this xml file.

 

Thanks,

dlovell


There is a VI in the LabVIEW examples that is very similar to the two VIs posted by Steve Chandler.

 

0 Kudos
Message 4 of 7
(3,593 Views)

Hey Steve,

So I am trying to test your VI you created but I can't get it to work. Are you suppose to put the location of the xml file in the "XML String"? No matter what I put into the XML String portion I can't get past the error "Invoke Node in Find Array.vi"

 

Thanks,

dlovell

0 Kudos
Message 5 of 7
(3,568 Views)

Hey  Steve,

Never mind I figured it out... Thanks I can't wait to apply this to my program!!

 

dlovell

0 Kudos
Message 6 of 7
(3,558 Views)

hi,

 

 

I need the working VI, is it possible to attach the updated working VI and I am using labview 2010 version

0 Kudos
Message 7 of 7
(3,475 Views)