Application Development and Automation Discussions
Join the discussions or start your own on all things application development, including tools and APIs, programming models, and keeping your skills sharp.
cancel
Showing results for 
Search instead for 
Did you mean: 
Read only

sy-datum?

Former Member
0 Likes
2,354

Hello!

I'm a beginner of abap....

I have:

PARAMETER: dat_up TYPE sy-datum,

dat_to TYPE dats.

I need to see a date in feld. value sy-datum????

Thanks!

1 ACCEPTED SOLUTION
Read only

Former Member
0 Likes
1,585

parameter:

date like sy-datum default sy-datum.

or

parameters:

date type d default sy-datum.

Hello!

I'm a beginner of abap....

I have:

PARAMETER: dat_up TYPE sy-datum,

dat_to TYPE dats.

I need to see a date in feld. value sy-datum????

Thanks!

9 REPLIES 9
Read only

Former Member
0 Likes
1,585

Hi,

In the Intialization event pass the value to date variable.

INTIALIZATION.

p_date = '20080512' or

p_date = sy-datum.

Using the DEFALULT we cant change the value in tehe selection screen but when passed in INITIALIZATION then we can reset the value

Thanks & Regards,

Chandralekha.

Read only

Former Member
0 Likes
1,585

PARAMETER: dat_up TYPE sy-datum,

dat_up = sy-datum.

Read only

Former Member
0 Likes
1,586

parameter:

date like sy-datum default sy-datum.

or

parameters:

date type d default sy-datum.

Read only

Former Member
0 Likes
1,585

Use following code

PARAMETER: dat_up TYPE sy-datum default sy-datum,
                               dat_to TYPE dats.

Read only

Former Member
0 Likes
1,585

hi Andrei Algaier

In initialisation events assign like this

initialisation

dat_up = sy-datum.

Read only

Former Member
0 Likes
1,585

PARAMETER: dat_up TYPE sy-datum,

dat_to TYPE dats.

initialization.

dat_up = sy-datum.

Read only

Former Member
0 Likes
1,585

Hi

write in initialization event

dat_up = sy-datum.

Regards

Adil

Read only

Former Member
0 Likes
1,585

Hi,

Check this sample code.


REPORT z_sdn.

PARAMETERS:
  p_dat TYPE sy-datum DEFAULT sy-datum.

WRITE: p_dat.

Regards

Abhijeet

Read only

Former Member
0 Likes
1,585

Hi,

This may serve your purpose...

PARAMETERS: p_date TYPE sydatum DEFAULT sy-datum.

For Displaying the Current Date, write the following code.

WRITE: p_date.

Thanks,

Ipsita

\[removed by moderator\]

Edited by: Jan Stallkamp on Jul 23, 2008 4:34 PM