Skip to Content
0
Former Member
Jul 10, 2006 at 07:28 AM

Get the current date

28 Views

Hi experts.

i'm trying to get the current date to field in my screen i'm wrote this code in the PBO MODULE

*----


MODULE set_Date OUTPUT.

DATA : LV_Curr_Date like ce3tamb-perbl,

LV_month(3),

LV_year(4).

LV_month = sy-datum+4(2).

concatenate '0' LV_month into LV_month.

LV_year = sy-datum(4).

concatenate LV_year LV_month into LV_Curr_Date.

S_PERBL-LOW = LV_Curr_Date.

ENDMODULE. " set_Date OUTPUT

*----


what strange is that in our dev-server its works fine but on the production it's not.

what i'm trying to do is to get the current month and year to the field S_PERBL-(Fiscal year/period block),so i'll use it for Variant to a job that will work everyday.

thanks in advance.

Gil.