Showing results for 
Search instead for 
Did you mean: 

Error (-2506) on reading TDMS file


I'm trying to read a particular TDMS file, in small chunks (20,000 samples) at a time and experiencing error -2506, when offset' reaches to 4700000.

First of all I thought that the file might be corrupt, however when I tried reading the complete file, it was accomplished like a charm.

Also I noticed that if the 'offset' is set to 4699999 while 'count' (samples to read) is set as -1, again there is no error and I get 120001 samples as output.

Is this an issue/bug with the TDMS read function?


Quick description of the file:

> 1 Group, 4 Channels with equal # samples (4820000) in each channel

> 35.7 MB (37,442,560 bytes)


Error description:

> Error code: -2506

> Possible reason(s): "LabVIEW: LabVIEW failed to read data from the TDMS file."

Below is simplified code.

Error -2506


PS: I'm working on, getting permission to share the TDMS file.

I am not allergic to Kudos, in fact I love Kudos.

 Make your LabVIEW experience more CONVENIENT.

0 Kudos
Message 1 of 5


I am not allergic to Kudos, in fact I love Kudos.

 Make your LabVIEW experience more CONVENIENT.

0 Kudos
Message 2 of 5

I'm getting the same problem with my TDMS file.

The TDMS file is not excessively large (24MB), however it have 250 groups (each group represents an animal) with 2 channels each one.





I read the TDMS file 250 times, to know the data of esch group (=animal data).



It starts reading the file properly, but after around 40, the error occurs.

I appreciate some suggestion.


Working with Win10/LV2011 SP1


0 Kudos
Message 3 of 5


Today, after restarting the computer, the VI has worked fine, reading all 250 groups.


Backing to the problem, even though the VI does have the TDMS Close function in each reading, I'm afraid the problem is located with the access permission. Perhaps does the TDMS close function failed?

0 Kudos
Message 4 of 5

After reading some sources about TDMS, I found the problem: it was a problem with the TDMS fragmentation. Because I 


  • write different channels to the same file alternately, and
  • write to multiple groups simultaneously

the fragmentation of the file occurs. So using the TDMS deframentation example solved my problem.


0 Kudos
Message 5 of 5