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/grayed parameter

Former Member
0 Likes
907

hi all,

how can i make my parameter to have default values and that there is no other options to put in this field, i mean i know how to make default value but how to gray it and restrict it from further changes i don't...

please help!

thanx a million!

maja

1 ACCEPTED SOLUTION
Read only

Former Member
0 Likes
819

HI MAJA,

try this........

parameter: p_kunnr like kna1-kunnr default '1'.

at selection-screen output.

loop at screen.

if screen-name = 'P_KUNNR'.

SCREEN-INPUT = 0.

MODIFY SCREEN.

ENDIF.

ENDLOOP.

do reward if it helps,

priya.

5 REPLIES 5
Read only

Former Member
0 Likes
819

Hi Maja,

Use DEFAULT option to initial a value to a PARAMETER

Use NO-DISPLAY option not to dispaly PARAMETER.

PARAMETERS: P_DATE(8)DEFAULT '20060321' NO-DISPLAY.

Thanks,

Vinay

Read only

Former Member
0 Likes
819

Hi maja,

In te at selection-screen ouput event.

do this.

at selection-screen output.

loop at screen.

if screen-name = 'P_NAME'.

screen-input = 0.

modift screen.

endif.

endloop.

Read only

Former Member
0 Likes
819

Hi!

You can protect the value of your selection using VARIANTS.

Save a selection variant and there you can tick every field to be protected.

Here's an example to fill a select-option field with more than 1 data.

  • Initialization

*----

-


INITIALIZATION.

CONCATENATE sy-datum(6) '01' INTO s_budat-high.

SUBTRACT 1 FROM s_budat-high.

CONCATENATE s_budat-high(6) '01' INTO s_budat-low.

MOVE 'I' TO s_budat-sign.

MOVE 'BT' TO s_budat-option.

APPEND s_budat.

MOVE '20070101' TO s_budat-low.

MOVE '20070131' INTO s_budat-high.

APPEND s_budat.

Regards

Tamá

Read only

Former Member
0 Likes
820

HI MAJA,

try this........

parameter: p_kunnr like kna1-kunnr default '1'.

at selection-screen output.

loop at screen.

if screen-name = 'P_KUNNR'.

SCREEN-INPUT = 0.

MODIFY SCREEN.

ENDIF.

ENDLOOP.

do reward if it helps,

priya.

Read only

Former Member
0 Likes
819
parameters: p_matnr like mara-matnr default '100000000000'.

at selection-screen output.
loop at screen.
 if screen-name = 'P_MATNR'.
   screen-input = '0'.
   modify screen.
 endif.
endloop.