Application Development 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: 

user-command in 'REUSE_ALV_HIERSEQ_LIST_DISPLAY'

Former Member
0 Kudos

Hai all,

I am trying to include a checkbox coloum in 'REUSE_ALV_HIERSEQ_LIST_DISPLAY' in edit mode and process the rows which are selected.

i am successful in editing the check box ,but user-command is not working and also the List is not displayed (remains only on the selection screen) if i am uncommenting the exporting parameter

I_CALLBACK_USER_COMMAND = 'F_USER_COMMAND' .

The value of sy-subrc for the FM is 1 . If the above exporting parameter is commented then sy-subrc = 0 .

Please let me know to proceed.I need to process only the rows which are selected / checked

.

CALL FUNCTION 'REUSE_ALV_HIERSEQ_LIST_DISPLAY'

EXPORTING

  • I_INTERFACE_CHECK = ' '

i_callback_program = report_name

  • I_CALLBACK_PF_STATUS_SET = ' '

<b>**{ Begin of Changes

  • I_CALLBACK_USER_COMMAND = ' '

I_CALLBACK_USER_COMMAND = 'F_USER_COMMAND'

**} End of Changes</b>

is_layout = alvlo_stb

it_fieldcat = stb_fields_tb[]

  • IT_EXCLUDING =

  • IT_SPECIAL_GROUPS =

  • IT_SORT =

it_filter = g_t_slis_filt[]

  • IS_SEL_HIDE =

  • I_SCREEN_START_COLUMN = 0

  • I_SCREEN_START_LINE = 0

  • I_SCREEN_END_COLUMN = 0

  • I_SCREEN_END_LINE = 0

i_default = g_f_dflt

i_save = 'A' "alvvr_sav_all

is_variant = alvvr

it_events = alv_evnt_tb_cmpl

  • IT_EVENT_EXIT =

i_tabname_header = 'ALV_STB'

i_tabname_item = 'G_T_PLPO'

  • I_STRUCTURE_NAME_HEADER =

  • I_STRUCTURE_NAME_ITEM =

is_keyinfo = g_f_keyinfo

  • IS_PRINT =

  • IS_REPREP_ID =

  • I_BUFFER_ACTIVE =

  • I_BYPASSING_BUFFER =

  • IMPORTING

  • E_EXIT_CAUSED_BY_CALLER = exit_by_caller

  • ES_EXIT_CAUSED_BY_USER = exit_by_user

TABLES

t_outtab_header = alv_stb

t_outtab_item = g_t_plpo

EXCEPTIONS

program_error = 1

OTHERS = 2

.

IF sy-subrc <> 0.

  • MESSAGE ID SY-MSGID TYPE SY-MSGTY NUMBER SY-MSGNO

  • WITH SY-MSGV1 SY-MSGV2 SY-MSGV3 SY-MSGV4.

ENDIF.

  • MOD0001}

ENDFORM.

FORM F_USER_COMMAND USING r_ucomm LIKE sy-ucomm

rs_selfield TYPE slis_selfield.

    • some operation

ENDFORM.

2 REPLIES 2

maciej_domagaa
Contributor
0 Kudos

Make sure that form routine F_USER_COMMAND is defined in the program and that you pass this program's name in parameter I_CALLBACK_PROGRAM (in your example: before "call function" you should have "report_name = SY-REPID" if F_USER_COMMAND is defined in the same program).

regards

Former Member
0 Kudos

Hai,

I have declared

DATA: report_name LIKE sy-repid,

and also

DATA: F_USER_COMMAND TYPE SY-UCOMM.

in the program.But still i am getting the same problem.

sy-subrc = 1. unable to execute 'REUSE_ALV_HIERSEQ_LIST_DISPLAY' sucessfully