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

Default values in Module pool

Former Member
0 Likes
3,870

Can I specify default values in screen.

for example for date I want to use default value sy-datum.

I dont want to write the code in screen flow logic.

screenfield-name = sy-datum.

Is there any other way for specify default value in screen?

6 REPLIES 6
Read only

Former Member
0 Likes
1,583

I think the only way is to assign the default values in the PBO only.

But for transactions, by creating the TRANSACTION VARIANTS you can given the default values and it is also possible to make it NON-EDITABLE or INVISIBLE as well.

Read only

0 Likes
1,583

Hi Santosh,

Can you just brief me about the transaction variants and how do I use in the screen

Read only

Former Member
0 Likes
1,583

Hi,

If you want to display as default values you can write the code in PBO only.

Regrds,

Nikhil.

Read only

awin_prabhu
Active Contributor
0 Likes
1,583

Hi Shah,

S we can do it.

In screen layout, -> Goto -> Secondary Window -> Dictionary/Program Fields -> Enter 'SYST' in Table name

-> Select DATUM field and place it in ur layout. If u want, u can change the text label for date also.

Save & activate.

It will contain today's date as default value.

Thanks,

Edited by: Sap Fan on Nov 12, 2009 8:31 AM

Read only

Former Member
0 Likes
1,583

Yap I took the field in syst structure.

But this is only for date for about other fields.

Read only

former_member632458
Participant
0 Likes
1,583

Hi,

Check the Screen field whether initial or not. if initial set the default vale in PBO.

In PBO Event

IF <Screen Field> IS INITIAL.

<Screen Field> = Default Value.

ENDIF.

Regards,

Rajesh S