Convert Date/Time to Decimal Variable

 

This option converts a Date/Time variable to a decimal value representing the date/time. The value is then saved to a Decimal variable. Create a Date/Time variable through the Variable tab in the Script Editor or through the Date/Time command.

 

 

Script Editor > Expand Variables Category > Convert Date/Time to Decimal

 

 

Date/Time Variable to Convert

Select the Date/Time variable to convert to a Decimal variable.

 

 

Decimal Variable to Receive the Result

Select the Decimal variable to store the value of the converted Date/Time variable.

 

 

Example:

Below is a sample date and time saved to a Date/Time variable:

8/8/2017 11:37:40 AM

 

The Date/Time variable value above converts to the decimal value shown below:

42955.4844978704

 

The first 5 digits represent the date. The decimal section, to the right of the period, represents the time (or fraction of a day).