LabVIEW

cancel
Showing results for 
Search instead for 
Did you mean: 

Saving data in axcel file

Hi, I want to save the data in an excel file...

 

In fact,I use a DAQ board and acquire signals from the muscles of a patient.

 

I want to save in the excel file the patient name, the date and the data that i had measured from the DAQ.

 

For the values of the DAQ, there are no problems since i am using the "write to speadsheet block"

 

Any help please. Thank you in advance

0 Kudos
Message 1 of 13
(3,275 Views)

If there are no problems, then what is your question?

 

Are you asking how to add a header? Since you are using Write To Spreadsheet File, simply call the VI before your loop, and wire in a 1D array of strings, or a 2D array of strings, that corresponds to your header (depending on how you want to format the header). Inside the loop just call the Write to Spreadsheet File with the "append" input set to true.

0 Kudos
Message 2 of 13
(3,271 Views)

Thank you for your reply.

 

The problem is that i can't save the sting of characters of the patient name, the date and the time... I couldn't integrate them using the "write to speadsheet block"... There was a problem with the data type. 

 

Thank you again

0 Kudos
Message 3 of 13
(3,265 Views)

Convert to strings.

0 Kudos
Message 4 of 13
(3,263 Views)

Are you trying to save the patient information as part of the file name or as part of the spreadsheet?

0 Kudos
Message 5 of 13
(3,257 Views)

As part of the spreadsheet...

0 Kudos
Message 6 of 13
(3,255 Views)

patient name is text so what exactly is the problem???

0 Kudos
Message 7 of 13
(3,244 Views)

Well, if I have a number and I need to call a function that takes in a string, I clearly need to convert the number to a string, right? Well, you obviously need to do the same thing. You need to format the date to a string. There are plenty of string functions that you can use. You can use the generic Format Into String function, or the datetime-specific ones in the Time palette. Look at the LabVIEW Help for these functions. They provide examples of the strings you get.

0 Kudos
Message 8 of 13
(3,241 Views)

I don't know how to save the patient name and hte data in a single spreadsheet

0 Kudos
Message 9 of 13
(3,240 Views)

Did you read my original response?

0 Kudos
Message 10 of 13
(3,237 Views)