Hi,
Please go to the report section and set the SourceExpr. in the properties of date format to FORMAT(TODAY,0,3) or FORMAT(TODAY,0,4). You will get the desired result.
And what exactly is your point? FORMAT is just another keyword in C/AL code, you just have to learn how to use it. It sure is easier to program one line of code as opposed to the 5 line snippet for which you have to create additional variables.
Comments
The FORMAT function might be of help to you.
d := TODAY;
month:=DATE2DMY(d,2);
day:=DATE2DMY(d,1);
year:=DATE2DMY(d,3);
DateText:=FORMAT(month)+'/'+Format(day)+'/'+Format(year);
GD
RIS Plus, LLC
Please go to the report section and set the SourceExpr. in the properties of date format to FORMAT(TODAY,0,3) or FORMAT(TODAY,0,4). You will get the desired result.
Example
This example shows how to use the FORMAT function.
MESSAGE(Text000, FORMAT(-123456.78, 15, 3));
Create the following text constant in the C/AL Globals window:
Text Constant
ENU Value
Text000
'The formatted value: >%1<'
The message window shows:
The formatted value: > 123,456.78 [-X
GD
RIS Plus, LLC