06-23-2014 04:40 AM - edited 06-23-2014 04:48 AM
I am trying to use a multicolumn listbox (Figure 1) as a file explorer. I had a look at the ListBox as File Explorer Demo example. I have a directory of files (XML & .txt) (Figure 2) what I need to do is take the ID of the .txt file which matches the ID of the XML file insert that into the ID of the listbox then take the start time, end time and metres inspected from the .txt file (Figure 3) and insert them into the listbox under their headers. The listbox is controlled as a double click event but the doubled clicked row needs to open the XML file of the matching ID of the .txt file
06-23-2014 04:50 AM
Your requirement is pretty clear, what is the problem you are facing. If you are stuck up somewhere please show where you are.
06-23-2014 04:54 AM
My issue is removing the elements from the .txt file into the listbox with the ID and then loading the corresponding XML file
06-23-2014 05:04 AM
Just list all the .txt files from the directory and check the name of each file and build the xml file with the same name and check whether the file exist or not. Is yes, Then read the .txt file (It seems to be a Tab delimited file) by using the spreadsheet read vi and update the time data along with the path converted as a string store it in an array/cluster. In the main VI populate the data on the table and depending on the row double clicked load the XML file. By the way what do you mean by Loading XML file? You want to display the contents on the FP?
06-23-2014 05:08 AM
By loading the XML file I mean using it as a file path control the elements in the listbox are just a GUI representation of the XML file for easier reading
06-23-2014 05:20 AM
Ok. Please give a try and come back if you stuckup somewhere