any2Date Function
Dynamics AX 2009
Converts an anytype value to a date value.
date any2Date(anytype object)
static void any2DateExample(Args _args)
{
date myDate;
str s;
int i;
;
s = "2010 6 17"; // A string object, of yyyy mm dd.
myDate = any2Date(s);
Global::info(strFmt("%1 is output, from input of \"2010 6 17\"", myDate));
i = 40361; // An int object, which represents the number of days from 1900/01/01.
myDate = any2Date(i);
Global::info(strFmt("%1 is output, from input of 40361", myDate));
}
/**** Infolog display.
Message (04:44:15 pm)
6/17/2010 is output, from input of "2010 6 17"
7/4/2010 is output, from input of 40361
****/
Community Additions
ADD
Show: