What are the function calls to get the System Date and Current Date using X++ in Microsoft Dynamics AX?
What is the function to get the system date and current date in Dynamics AX?
Use the static methods within class DateTimeUtil:
Both return UTC date and times, but will be converted to local time on display.
See Best Practice.
systemDateGet() and Today()
In Dynamics Ax < 2009
Current Date:
Today()
The system date provided by the today function should be used only where the actual machine date is needed.
System Date:
SystemDateGet()
Most application logic should use the system function systemDateGet, which holds the logic date of the system.
SystemDateGet() is the command to get current date in a display method.
today() method, which might return a different date (it returns the machine date, not the date from Dynamics AX).
© 2022 - 2024 — McMap. All rights reserved.
SystemDateGet
is deprecated, use the methods fromDateTimeUtil
instead. – Whirlpool