cancel
Showing results for 
Search instead for 
Did you mean: 
Subscribe

Hi Gurus,

In BSP application, we need to show users the time of business process trigger. But, that time is as per application server. After fetching that timestamp, we need to add two hours in it to convert it to CET. For e.g. the process triggered at 23:00:00 on 22 July 2008 should automatically convert to 01:00:00 and date 23/07/2008. Please give me pointer if there is any such function module where i can give offset and get my time converted. This should also take care of leap year, months with 31 days and so on.

Thanks and Regards,

Harpal

0 Likes
View Entire Topic
Former Member
0 Likes

I found one function module named C14B_ADD_TIME. The code for which is

FUNCTION C14B_ADD_TIME.

*"----


""Lokale Schnittstelle:

*" IMPORTING

*" VALUE(I_STARTTIME) TYPE T

*" VALUE(I_STARTDATE) TYPE D

*" VALUE(I_ADDTIME) TYPE T

*" EXPORTING

*" VALUE(E_ENDTIME) TYPE T

*" VALUE(E_ENDDATE) TYPE D

*"----


DATA : DIFFERENZ TYPE I.

E_ENDTIME = I_STARTTIME + I_ADDTIME.

DIFFERENZ = E_ENDTIME - I_STARTTIME.

IF DIFFERENZ < 0.

E_ENDDATE = I_STARTDATE + 1.

ELSE.

E_ENDDATE = I_STARTDATE.

ENDIF.

ENDFUNCTION.

Thanks and Regards,

Harpal