LabVIEW

cancel
Showing results for 
Search instead for 
Did you mean: 

How do I use Write to Spreadsheet VI

Solved!
Go to solution

HI,

 

      I want to record the incomming data collected from my experiment into a spreadsheet that can be opened in excel.  I have used the Write to Spreadsheet vi but when I run the program a file is not generated.  I enter the path for the file and run the program. When I stop the program though, no file exists.

 

    I am using Labview 8.6 and have attatched my program.   Any suggestions would be appreciated.

 

Thanks

0 Kudos
Message 1 of 4
(2,754 Views)
Solution
Accepted by topic author Melioris
Are you stopping the program with thefront panel Boolean? After changing that first while loop, I ran it and it created a file.
Message 2 of 4
(2,740 Views)

You should also keep in mind that that VI will not generate a spreadsheet or anything related to Excel. It generates a text file that you can import into Excel.

 

A few comments regarding the VI:

  • Your use of local variables is unnecessary, and the End local variable is actually a race condition. Which will happen first? The reading of the local variable, or the updating of the indicator with the new value? You can't be sure. Use wires.
  • The sequence frame inside the loop (the one with the VISA functions) doesn't do anything, and can be eliminated.
  • You have sliders which have their digital displays shown, and you also have separate numeric controls. Is there a reason for this?
Message 3 of 4
(2,729 Views)

I had not been stopping the program with the boolean stop.  That fixed it.  I should of thought of that before.  Thanks.

 

In response to the other comment:

 

1.  I don't need that code.  I have just not deleted it yet.

2.  I will remove the sequence frames.

3.  There is a reason for the seperate numeric controls.  I am using labview to help me control and characterize a micro air vehicle.  The sliders and the numeric controls are needed so I can test the aircrafts characteristics.

 

Thanks for all of your help.

0 Kudos
Message 4 of 4
(2,704 Views)