In the selection of the screen s_bwart movement type, the range is as follows:
ReportZ_test.
Tables: T156t.
data : ltab_fields like help_value occurs 0 with header line ,
begin of ltab_values occurs 0 ,
Feld ( 40 ) type C ,
end of ltab_values.
selection- screen begin block blk1 with Frame title text - 001 .
select -options:
s_bgat< SPAN class = "l1s52"> for t156t-bwart obligatory default '20140901' . "mobile type
selection- screen end of block blk1.
AtSelection-Screen On Value-RequestForS_bwart-low.
PerformGet_bwartUsingS_bwart-lowText-002.
AtSelection-Screen On Value-RequestForS_bwart-high.
PerformGet_bwartUsingS_bwart-highText-003.
* Initialization selection screen
Initialization.
Ltab_fields-tabname ='T156t'.
Ltab_fields-fieldname ='Bit'.
Ltab_fields-selectflag ='X'.
AppendLtab_fields.
Ltab_fields-tabname ='T156t'.
Ltab_fields-fieldname ='Text'.
Ltab_fields-selectflag = space.
AppendLtab_fields.
* -- Fill values
Select * From T156t
Where Spras = 1 And Sobkz = '' And Kzbew = '' And Kzzug = '' And Bits In ( '123' , '123' , '123' , '123' ,'123' , '123' , '123' , '123' , '123' , '123' , '123' , '123' ).
Ltab_values-feld = T156T-BWART.
Append Ltab_values.
Ltab_values-feld = T156T-BTEXT.
Append Ltab_values.
Endselect .
Start-Of-Selection.
End-Of-Selection.
*&---------------------------------------------------------------------*
* & Form get_bform
*&---------------------------------------------------------------------*
* Text
*----------------------------------------------------------------------*
* --> P_p_b1_text
* --> P_text_003 text
*----------------------------------------------------------------------*
Form Get_bwart Using P_b133
P_text_003.
Call Function 'Help _ values_get_with_table'
Exporting
Fieldname = 'Bit'
Tabname = 'T156t'
Title_in_values_list = 'Select A value'
Importing
Select_value = p_b133
Tables
Fields = Ltab_fields
Valuetab = ltab_values
Exceptions
Field_not_in_ddic =01
More_then_one_selectfield = 02
No_selectfield = 03 .
Endform . "Get_bwart
------------------------------------------------------------------
Drop-down menu with a few fixed values:
Parameters: P_sobkzTypeZynAsListBox visible length3,
Create the zyn field and add the value to be displayed in the drop-down menu in value range.