LabVIEW

cancel
Showing results for 
Search instead for 
Did you mean: 

how do you create a files while incrementing name

I'm trying to create a file every time a certain criteria is reached, for this example, every time that my ratio gives a whole number a true is sent to my case and I would like to create a file... but I always get an error, that my path doesn't exist.  I need a new file created everytime that I go into my case, so I'm using a shift register to do that... eventually what I'm tryign to do is write a buffer into a tdms file and save it on my hard drive every time I go into my True case... but I'm stuck on just creating a file.... could someone tell me wha tI'm doing wrong?

 

Thanks!

Download All
0 Kudos
Message 1 of 5
(2,962 Views)
You have to select "open or create" input selector to the open/create/replace file.vi
PaulG.
Retired
0 Kudos
Message 2 of 5
(2,956 Views)

I tried that but then ran into errors when I passed the path to the TDMS... now I'm trying to use TDMS open, with the open or create input selected, but still errors... is this not how you open or create a tdms file to write to it?

 

Thanks!

Download All
0 Kudos
Message 3 of 5
(2,954 Views)
You don't need the '\' character in the first string of Concatenate String. That should fix it. If that still doesn't work, try using an absolute path instead of a relative one. If you have saved the VI, then you can use Current VI's Path node.
Adnan Zafar
Certified LabVIEW Architect
Coleman Technologies
0 Kudos
Message 4 of 5
(2,936 Views)

Hello Fibo,

 

There is an excellent example that is included in LabVIEW.  You can access it by selecting Help»Find Examples. Then search for TDMS.   There are several examples for you to look at.  The one I think would be most helpful is TDMS - Write Data (Events).vi.  Let me know if this solves your problem.

Regards,

Jon S.
National Instruments
LabVIEW NXG Product Owner
0 Kudos
Message 5 of 5
(2,903 Views)