Skip to Content

Archived discussions are read-only. Learn more about SAP Q&A

Last Date of the next month

Hi,

How to find the last date of the next month.

Thanks in advance

Sunitha

Tags:
replied
REPORT ychatest.

DATA : date1 LIKE sy-datum,
       month(2).


date1 = sy-datum.
month = date1+4(2).
month = month + 1.
date1+4(2) = month.

CALL FUNCTION 'SG_PS_GET_LAST_DAY_OF_MONTH'
  EXPORTING
    day_in            = date1
  IMPORTING
    last_day_of_month = date1
  EXCEPTIONS
    day_in_not_valid  = 1.


WRITE : date1+6(2).
.
0 View this answer in context
Not what you were looking for? View more on this topic or Ask a question