It looks like you're new here. Sign in or register to get started.
datEndOfMonth := CALCDATE('<CM>',datSomeDate);
datStartOfMonth := CALCDATE('<-CM>',datSomeDate);
IF DATE2DMY(dateValue,2) < 12 THEN dateLast:=DMY2DATE(1,DATE2DMY(dateValue,2)+1,DATE2DMY(dateValue,3)) ELSE dateLast := DMY2DATE(1,1,DATE2DMY(dateValue,3)+1); dateLast := CALCDATE('-1D',dateLast);
Asallai wrote: Do you mean the Last Day of a month?
kriki wrote: datEndOfMonth := CALCDATE('<CM>',datSomeDate);
DenSter wrote: Asallai wrote: Do you mean the Last Day of a month? Yes that is what he meant, and you do not need that much code, there is a very simple CALCDATE commend for that: kriki wrote: datEndOfMonth := CALCDATE('<CM>',datSomeDate);
Answers
No PM,please use the forum. || May the <SOLVED>-attribute be in your title!
RIS Plus, LLC
Input: dateValue
Output: dateLast
RIS Plus, LLC
Thanks! Better late then never!