LabVIEW

cancel
Showing results for 
Search instead for 
Did you mean: 

date & time on data sheet

I have a large program that refuses to print the date and time on the data sheet after running a test. However it does print the required data but the date and time missing. I have attached a mini program that prints date and time on the data sheet. I am still using labview 6.0. Can someone point out why my bigger program has problems?
0 Kudos
Message 1 of 18
(3,770 Views)
Posting a VI that works is not the best way to get an answer to a problem. And, what do you mean "print the date and time on the data sheet"? Your example writes the date/time to the front panel and doesn't do any printing. If you want your main program to write to the front panel and nothing is being written, verify that the section of code is actually being exectued (maybe it's inside a case statement that's not run) or you're clearing the indicators after they've been written. Are you clearing them by writing an empty string to a local variable?
Message 2 of 18
(3,768 Views)

"Your example writes the date/time to the front panel and doesn't do any printing"

I actually want to save date/time on my data file which is saved. When I open my "old" saved data files, I do not know when was the data collected. The date/time appears on the front panel but not the saved data file.

0 Kudos
Message 3 of 18
(3,741 Views)

Well, if you're not writing the date/time to the file, then you won't know when it was created unless you use the file creation date/time. Do you think the file write should have the date and time in it and you don't understand why it's not there? The example you posted only writes "what is which" to a file. You would actually have to wire the output of your concantanate strings to a file write function in order to actually save it.

Message 4 of 18
(3,733 Views)
I have added the concated string but still it saves only "what is which" but no date/time. The vi in LV 6.0 is attached.
0 Kudos
Message 5 of 18
(3,721 Views)
hi ,lv19
here I change your code a litter.
Is it ok?
I will be online all the time.
 
Message 6 of 18
(3,712 Views)

Hii, LV19 and Fay,

               Fay thats a good solution but i dont understand why he is using Write Character to file.vi, he also can use the write to spreadsheet file or Open, Write snd close file, that is the better solution, rather than this and to timestamp the data is not a donting task, its an easier, even milisecond data can also been time stamped.

Thanks,

Nishant

Message 7 of 18
(3,705 Views)
Do you expect the output of the concantanated string to magically jump to the input of the Write Characters to File? In order for that function to actually write some data to a file, that data has to be connected to the input "character string". What you're doing doesn't make any sense at all. You might want to look into taking a very basic LabVIEW course to get you started.
Message 8 of 18
(3,686 Views)

labview1958 wrote:
I have added the concated string but still it saves only "what is which" but no date/time. The vi in LV 6.0 is attached.

1958,

This is the inverse of your  first post to this forum in which date/time was saved, but not the data.

Hope the attached helps in some way.  It is most likely the same as Fay's, but is saved in LV v6.0.

Plus ca change ...

=====================================================
Fading out. " ... J. Arthur Rank on gong."
Message 9 of 18
(3,671 Views)

Afterthought:

1958,

If in your "bigger program" you need the sequence structure, what you may be in need of learning about is the use of "sequence locals" to pass data between frames of a sequence structure.   They're discussed in the online help/examples.

... c'est la meme chose.

=====================================================
Fading out. " ... J. Arthur Rank on gong."
Message 10 of 18
(3,660 Views)