Application Development Discussions
Join the discussions or start your own on all things application development, including tools and APIs, programming models, and keeping your skills sharp.
cancel
Showing results for 
Search instead for 
Did you mean: 

Need start date & end date for MMYYYY

Former Member
0 Kudos

HI ,

I need to find start date & end date of MMYYYY.

Is there any FM to do this??

thanks

Moderator comments: 1st warning.

Pl read the rules of engagement & [Date questions not allowed|/thread/1360534 [original link is broken];

Awarded points are unassigned & the thread is locked.

Edited by: Suresh Datti on Aug 6, 2009 4:14 AM

1 REPLY 1

venkat_o
Active Contributor
0 Kudos

Hi Karthik, Try this way.

 REPORT ZTEST_NOTEPAD.
PARAMETERS :p_month(2) type n,
            p_year(4)  type n.
data:first_day LIKE  VTBBEWE-DVALUT,
     last_day  type datum,
     days(2)   TYPE c.
"First date of the month
CONCATENATE p_year p_month '01' INTO first_day.
CALL FUNCTION 'END_OF_MONTH_DETERMINE_2'
  EXPORTING
    i_datum        = first_day
 IMPORTING
   E_TT           = days.
"Last date of the month
CONCATENATE p_year p_month days INTO last_day.

WRITE:/ first_day,
      / last_day.
Thanks Venkat.O