LabVIEW

cancel
Showing results for 
Search instead for 
Did you mean: 

converting time stamp to double

Hello,

 

I am currently using the write to spreadsheet file.vi to save data.

 

It looks something like this:

 

18893i4FE97741C14A2B8F

 

I also want to add the date and time stamp into the saved data but do not know a way of converting a date and time stamp to 'double format'. When the date and time stamp is in teh double format I can easily concatenate the data stream with the 'date and time' in a 2-D array.

 

Thanks,

 

Nevica

0 Kudos
Message 1 of 11
(25,283 Views)

Look on the math palette.

 

18899iAF35943D3543F3E1

Tim
GHSP
Message 2 of 11
(25,279 Views)

What I would like to do is convert a date and time stamp (which has the form something like this: xxxx/xx/xx  xx:xx:xx) to a 'double'. The problem I am having is the non-numeric characters.

0 Kudos
Message 3 of 11
(25,264 Views)

Like this

Tim
GHSP
0 Kudos
Message 4 of 11
(25,255 Views)

Hello,

 

Thanks for your example. BUT in your example your are converting a number to a double precision float. I want to convert a string to a double. The problem I am having is the formatting of the date and time stamp which includes '/' (forward slashes) and ':' (colons).

 

Any ideas anyone?

 

Thanks,

 

Nevica

0 Kudos
Message 5 of 11
(25,242 Views)
0 Kudos
Message 6 of 11
(25,237 Views)

Could you not use "Get Date/Time in Seconds"?

 

Jim

Jim

LV 2020
0 Kudos
Message 7 of 11
(25,234 Views)

 


@nevica wrote:

Hello,

 

Thanks for your example. BUT in your example your are converting a number to a double precision float. I want to convert a string to a double. The problem I am having is the formatting of the date and time stamp which includes '/' (forward slashes) and ':' (colons).

 

Any ideas anyone?

 

Thanks,

 

Nevica


 

You asked how to convert a timestamp - not a string.

 

You can use the Scan From String.

 

0 Kudos
Message 8 of 11
(25,218 Views)

My apologies for not being clear.

 

It looks like get date and time in seconds will work as you have both suggested.

 

Nevica

0 Kudos
Message 9 of 11
(25,210 Views)

aeastet - nice icon

 

Jim

LV 2020
0 Kudos
Message 10 of 11
(25,195 Views)