From Friday, April 19th (11:00 PM CDT) through Saturday, April 20th (2:00 PM CDT), 2024, ni.com will undergo system upgrades that may result in temporary service interruption.

We appreciate your patience as we improve our online experience.

LabVIEW

cancel
Showing results for 
Search instead for 
Did you mean: 

Save Date and Time Strings in TDMS Group

I'm writing some numeric data to a TDMS file, but since our testing is going to take a few hours, we would like to save the date and time as well.  The date and time come out as strings, and though I'm aware we can save those in seconds, I'd really like to keep them in their string format.  Right now I'm just trying to add the data as a string group which I've called 'Timing Data'.

 

The VI that I've attached captures the essence of what I'm trying to do.  I would like to save two channels of string data.  The first channel will be 'Date' and the second channel will be 'Time'.  I've wired it up the same way I've done my numeric data, but it breaks.  The TDMS write file is a black box.  I can wire either the string data or the channel names and it works.  As soon as I wire the remaining terminal, it changes the data type that particular terminal will accept.  I don't care too much how it saves data as long as it does.

 

I've also tried using two separate write TDMS blocks with each dedicated to a single channel within the group, but it doesn't like taking a single string input into the channel name and data terminals, just as it doesn't like taking 1-D string arrays.

 

Any ideas on how I can save this string data to my TDMS file?

Download All
0 Kudos
Message 1 of 2
(2,378 Views)

You must wired a 2D array as the input of TDMS Write in your case like the attachment.

0 Kudos
Message 2 of 2
(2,356 Views)