DayOfYear

Top  Previous  Next

S

A

W

WS

ü

ü

Syntax -

DayOfYear <variable name> <DateValue1>

        Where:

       <variable name> is the user defined name that is assigned to the variable.

       <DateValue1> is a literal string that represents a valid date or a variable that contains a date.

 

Description:

This command is used to value the <variable name> with the total number of days that have occurred since the beginning of the year that is in the <DateValue1>.  This is also known as the Julian Date.

 

Sample 1:

       The following statement uses the DayOfYear command to determine the number of days since the beginning of the year 2004.

DayOfYear DY "2/20/2004"

 

Sample 2:

       The following statement uses the DayOfYear command and the Reserved Variable Name, &TODAY, to determine the number of days since the beginning of the current year.

DayOfYear DW &TODAY