07-02-2007 1:16 PM
hi experts,
cud u plz send me the function module in which when i enter the start and end date it will give me the number of days between these two dates ...thnx in advance
07-02-2007 1:24 PM
07-02-2007 1:23 PM
Hello,
USe this <b>DAYS_BETWEEN_TWO_DATES</b>
CALL FUNCTION 'DAYS_BETWEEN_TWO_DATES'
EXPORTING
I_DATUM_BIS = G_T_PURO-AEDAT
I_DATUM_VON = G_T_EBAN-BADAT
IMPORTING
E_TAGE = G_F_DIFF
EXCEPTIONS
DAYS_METHOD_NOT_DEFINED = 1
OTHERS = 2.
WRITE: G_F_DIFF.
Vasanth
07-02-2007 1:24 PM
07-02-2007 1:30 PM
Hi,
DAYS_BETWEEN_TWO_DATES
DATE_CONVERT_TO_FACTORYDATE.
FIMA_DAYS_BETWEEN_TWO_DATES_2
or FIMA_DAYS_BETWEEN_TWO_DATES.
<b>Reward points</b>
Regards
07-02-2007 1:40 PM
Hi,
use code as below :
data : days type VTBBEWE-ATAGE, years type VTBBEWE-ATAGE, months type VTBBEWE-ATAGE.
data : a_new type sy-datum, b_new type sy-datum.
a_new = '20070101'.
b_new = '20070130'.
CALL FUNCTION 'FIMA_DAYS_AND_MONTHS_AND_YEARS'
EXPORTING
i_date_from = a_new
I_KEY_DAY_FROM = '00'
i_date_to = b_new
I_KEY_DAY_TO = '00'
I_FLG_SEPARATE = ' '
IMPORTING
E_DAYS = days
E_MONTHS = months
E_YEARS = years.
write : days.
Reward points, if helpful,
Sandeep Kaushik