04-10-2007 10:36 AM
Hi ,
Is there any FM for to get a week from date and time. I am looking for a function module which gives a week starts from SUN 6PM and week ends
SUN 6PM by passing a date.
Thanks,
Vind.
04-10-2007 10:40 AM
did u check the fm <b>GET_WEEK_INFO_BASED_ON_DATE</b>
also check these fm's
WEEKDAY_GET Calendar: Get day of the week
WEEKNR_GET Calendar: Fetch Week Number
DATE_GET_WEEK Returns week for a date
WEEK_GET_FIRST_DAY Return first day for a week
Message was edited by:
Rajesh
04-10-2007 10:40 AM
hi,
Use GET_WEEK_INFO_BASED_ON_DATE.or
HR_IE_NUM_PRSI_WEEKS- Will return the number of weeks between two dates.
CALL FUNCTION 'GET_WEEK_INFO_BASED_ON_DATE'
EXPORTING
DATE = I_EKET-EINDT
IMPORTING
WEEK = OUTWEEK
* MONDAY =
SUNDAY = I_EKET-EINDT.
IF YOU PASS THE DAY (I_EKET-EINDT) IT WILL GIVE THE WEEK INFORMATION AND SUNDAY(1ST DAY).
Regards,
Santosh
04-10-2007 10:42 AM
The FM WEEK_GET_FIRST_DAY wil get the first day of the week if you pass the date.
add 7 to the today's date and use the same FM to get the first day of the next week.
Subtract 1 from that date. YOu would get the last day of the week.
Use WEEKNR_GET to get the week number for the current date
Regards,
Ravi
04-10-2007 10:48 AM
Hi ,
I am looking for a function module which gives a <b>week starts from SUN 6PM</b> and <b>week ends SUN 6PM</b> by passing a date.
Thanks,
Vind.