‎2010 Mar 31 2:49 PM
All abaper:
As per my client requirement from Invoice Date and Payment Term we have to calcute Due date.
For e.g Invocei Date 12.11.2008 and Payment Terms 120 Days, so the Due date is 12.03.2009.
Could u help me with the functional module whereing i will pass the date(12.11.2008) and payment terms(120), so that i will get the due date as (12.03.2009).
Regards,
Shegar
SAP-ABAP Consultant.
‎2010 Mar 31 2:58 PM
Hi
define your data field as sy-datum.
if you add 120 it calucate automatically the new date
data: dat_a type sy-datum,
dat_b type sy-datum.
dat_a = '20081112'.
dat_b = dat_a + 120.
dat_b will '12.03.2009'
regards
Marco
‎2010 Mar 31 2:55 PM
Hi,
There is no function module as such. But why do you need to call FM for such requirement. You can directly add 120 to the date to get the required result.
Do like this:
g_date = sy-datum.
g_threshold = g_date + 120.
It will solve your problem.
Thanks & Regards
Rocky Agarwal
Edited by: Rocky Kr. Agarwal on Mar 31, 2010 3:55 PM
‎2010 Mar 31 2:58 PM
Hi
define your data field as sy-datum.
if you add 120 it calucate automatically the new date
data: dat_a type sy-datum,
dat_b type sy-datum.
dat_a = '20081112'.
dat_b = dat_a + 120.
dat_b will '12.03.2009'
regards
Marco
‎2010 Mar 31 3:06 PM
Dear Menegazzo Marco :
Your answer was really very helpful for me,
Thanks
shegar
‎2010 Mar 31 3:03 PM