Hi Aneel,
Try.
Delcare internal table containing only GL
Data : it_return TYPE STANDARD TABLE OF ddshretval,
wa_return LIKE LINE OF it_return,
AT SELECTION-SCREEN ON s_comp.
if s_comp is initial.
message 'enter company code'' type 'E'.
else.
use select query to fill the gl contents based on company code.
endif.
AT SELECTION-SCREEN ON VALUE-REQUEST FOR so_hkont-low.
CALL FUNCTION 'F4IF_INT_TABLE_VALUE_REQUEST'
EXPORTING
* DDIC_STRUCTURE = 'SKA1'
retfield = 'SAKNR'
* PVALKEY = ' '
* DYNPPROG = sy-repid
* DYNPNR = sy-dynnr
* DYNPROFIELD = 'EBELN'
* STEPL = 0
window_title = 'Melt Numbers'
* VALUE = ' '
value_org = 'S'
* MULTIPLE_CHOICE = 'X' "allows you select multiple entries from the popup
* DISPLAY = ' '
* CALLBACK_PROGRAM = ' '
* CALLBACK_FORM = ' '
* MARK_TAB =
* IMPORTING
* USER_RESET = ld_ret
TABLES
value_tab = melt_dis
* FIELD_TAB = lt_field
return_tab = it_return
* DYNPFLD_MAPPING =
EXCEPTIONS
parameter_error = 1
no_values_found = 2
OTHERS = 3.
READ TABLE it_return INTO wa_return INDEX 1.
so_melt-low = wa_return-fieldval. " storing the selected gl values.
ENDIF.
AT SELECTION-SCREEN ON VALUE-REQUEST FOR so_hkont-high.
call the function module once again.
Hope it helpful,
Regards,
Venkat.