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

parameter.

Former Member
0 Likes
793

"parameter : p_blart like bkpf-blart"

This is my parameter for document type. When I am executing my report it is all documnet type when I am clicking to it. I want to restrict it to 'kg' and 'dg' onl. What I have to do for that.

1 ACCEPTED SOLUTION
Read only

Former Member
0 Likes
736

Hi,

Put a condition in ur select query as where bkpf-blart = kg

and bkpf-blart = dg.

Thanks

6 REPLIES 6
Read only

Former Member
0 Likes
737

Hi,

Put a condition in ur select query as where bkpf-blart = kg

and bkpf-blart = dg.

Thanks

Read only

Former Member
0 Likes
736

Hi,

Put KG and DG into one internal table.

In the event at selection screen on value-request for p_blart.

Use the FM F4_if_int_table_display to get the pop up with those two values.

Regards,

Read only

Former Member
0 Likes
736

Hi Abhay,

Use Ranges for that.

Refer this code :

Ranges : p_blart for bkpf-blart.

p_blart-SIGN = C_I.

p_blart-OPTION = C_EQ.

p_blart-LOW = C_IN.

APPEND p_blart.

CLEAR p_blart.

p_blart-SIGN = C_I.

p_blart-OPTION = C_EQ.

p_blart-LOW = C_QT.

APPEND p_blart.

CLEAR p_blart.

Select * from bkpf into corresponding fields of table i_bkpf where blart in p_blart.

Rewad points if helpful.

Regards,

Hemant

Read only

Former Member
0 Likes
736

Hi Abhay...

Didi you mean having default value in the selection screen.,... you can set the default value by...

In the INITIALIZATION event we can set the default values for selection screen fields.

INITIALIZATION.

loop at screen.

if screen-name = 'S_MATNR-LOW'.

CLEAR S_MATNR.

s_matnr-low = '1234'.

s_matnr-option = 'EQ'.

s_matnr-sign = 'I'.

append s_matnr.

CLEAR S_MATNR.

s_matnr-high = '5678'.

s_matnr-option = 'EQ'.

s_matnr-sign = 'I'.

append s_matnr

clear s_matnr.

endif.

endloop.

Hope it helps,

Regards,

Jayant

Read only

hymavathi_oruganti
Active Contributor
0 Likes
736

u can do like this.

in

declare the variable not as parameter but as select-option with no intervals and no extension.

define ranges statement

ranges r_value like ......

r_value-low =........

r_value-high = ........

append r_rvalue.

AT SELECTION- SCREEN

if variable not in ranges .

MESSAGE TYPE 'E'

Message was edited by:

Hymavathi Oruganti

Read only

Former Member
0 Likes
736

hi,

data : begin of itab_bkpf,

blart like bkpf-blart,

end of itab_bkpf.

parameter : p_blart like bkpf-blart.

select blart from bkpf into table itab_bkpf where bkpf = 'kg' and

bkpf = 'dg'.

reward with points if helpful.