LabVIEW

cancel
Showing results for 
Search instead for 
Did you mean: 

automatically creating data filename out of date and time information

Oops, one more thing. If you add your extension ("*.txt") at the end of the format string, and then convert this to a path, you don't need to do anything else in order to create your filename. The beauty of the format string is you can add anything you want to it.
Message 11 of 19
(1,730 Views)
Hi

Thanks for Bringing this to Attention. I tried the Function with %c which Gave the Date as mentioned. I did not try to input the Other Format Strings. My Mistake. You Can never be too Careful!! Or Take Anythinhg for Granted.

Regards,

Mache
Good Luck!

Mache
0 Kudos
Message 12 of 19
(1,494 Views)
Hi Mache...
I having the same problem as Terry. When I saved using the save dialog box, I would like the filename be generated according to the date,time and a given name .. (eg. SerialNO_DATE_TIME ). Unfortunately, I can't open you example which you have created : Modified DateStamped Filename due to my Labview version 6.02. Could you please save it at version 6.02?

Very appreciated if you could help me out here.
Thank you.

Mei88
0 Kudos
Message 13 of 19
(1,494 Views)
Hi Mache...
I having the same problem as Terry. When I saved using the save dialog box, I would like the filename be generated according to the date,time and a given name .. (eg. SerialNO_DATE_TIME ). Unfortunately, I can't open you example which you have created : Modified DateStamped Filename due to my Labview version 6.02. Could you please save it at version 6.02?

Very appreciated if you could help me out here.
Thank you.

Mei88
0 Kudos
Message 14 of 19
(1,494 Views)

In reference to, "Oh!! By the Way Once you have the File Path in the "Silent" Case you will have to Wire "NEw File" and "Write File" Funtions to save your data. I hope you can take it from here.

Mache ",
can some one explain the changes that are required to operate vi in "silent" mode?

The vi works fine until I output the path to a "write to spreadsheet" vi.

Thanks,

Wayne Hilburn

 

0 Kudos
Message 15 of 19
(1,464 Views)
Have you tried Labviewguru's method?  It is the one I use without any problems.

What sort of error are you getting?
0 Kudos
Message 16 of 19
(1,448 Views)

I tried that method and it worked!

Thanks,

Wayne

0 Kudos
Message 17 of 19
(1,435 Views)

One thing I might add to this that may be helpful:

I've done this kind of thing, but not only did I have to create such .txt files in existing Windows folders, but I had to create folder components of a .txt file's entire path on the fly. No dialogs allowed, because the application will run for a long time unattended.

Formatting the timestamp and getting it into the filename wasn't too hard. But then I got errors of the type "file doesn't exist." The solution was to check whether a folder component of the .txt's path was an existing directory, and if not, create it and wire the output path to the next "build path" etc.

::Marty

0 Kudos
Message 18 of 19
(1,430 Views)
I agree, Marty.  The more automated the system is, the more checks you have to make to ensure that everything ticks along nicely.

Another twist on filename tricks:
One of my test systems generates so much data that if I attempt to both gather and analize in the same .vi, I constantly run out of memory.  So, I have one .vi to gather the data and two to analyze (the analysis can be vastly different depending on the test parameters).  I use the filename of the raw data to transmit the test metadata from one .vi to the other.  Things like test pressure, date, time, log number, etc. are now part of the permanent record;  allowing me to easily revisit past tests.
0 Kudos
Message 19 of 19
(1,426 Views)