Showing results for 
Search instead for 
Did you mean: 

Write data with date format into TDMS

Go to solution


I'm trying to save data into TDMS.  I wonder if it is possible to configure a channel with only date format instead of date/time format. When I take a look the values through TDMS viewer, something like this is shown: "09/09/2016 00:00:00" rather than "09/09/2016". Also, when I click on Analog values to see the graph, the X-axis is not correct.

I suppose I missing something.


Thank you


Download All
0 Kudos
Message 1 of 5

The data stored in the TDMS file is binary, so it isn't saving anything related to how to display the data.  The format is coming from the TDMS viewer which is actually a LabVIEW VI.


You could make a copy of that VI and modify so that it displays the data in the format you want.


I'm not sure how you want the graph to look.  Your date data is just a series of points with the exact same value of just the date.  The graph is probably assuming that the data is a waveform datatype with a dT of 1 starting at a time of 0, which is why it starts at 1/1/1904 and goes to 50 seconds at the first gridline, probably because you have about 50 points or more in there.


I am also going to guess your time zone is GMT +1 because it is showing the time at 1 am on Jan 1, 1904.

Message 2 of 5

I had a hunch that the data stored is not related to how the data is displayed, as you say. However when you store data you are in fact defining the format it will be read later (otherwise an error will happen - see picture). So, a doubt has been going round in my head during these days:

When I use labview functions to manage TDMS, i.e. TDMS read function,  is it relevant to use string or numeric format? Is it faster to use numeric values to the detriment of strings?


Thank you



Using LabVIEW 2010/2011/2012 on WinXP




0 Kudos
Message 3 of 5
Accepted by topic author vicens

No, with the TDMS Read you aren't defining the format that the data will be read.  You are defining the datatype.


You are always better off saving it as numbers in a binary format.  There is no loss of data, and it would usually take fewer bytes.  Worry about formatting when you read it back as numbers and deciding how you want to display it.

Message 4 of 5

Thank you!



0 Kudos
Message 5 of 5