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

ALV SELECT CHECKBOX

Former Member
0 Likes
632

Hello Experts,

I am Displaying itab With checkbox.

In MY itab 150 rows and every Row has a checkBox, I am Using Reuse_Alv_Grid_display.

First user filter the itab with matkl , Then he got 15 row.

The User Requirement is How They Can Selected Multiple Rows(select all)(15 rows) at 1 time , Means Every Check box checked .

Thanks.

Regards: Heman(A1).

1 ACCEPTED SOLUTION
Read only

rvinod1982
Contributor
0 Likes
596

Hi Hemat,

First define gd_layout TYPE slis_layout_alv.

Then set property gd_layout-box_fieldname = 'Checkbox fieldname'.

It is not required to create the fieldcatalog for the checkbox field and display the checkbox field separately.

Then the user can select all the rows by just clicking the green color icon in the grid or by using F5 function key.

Regards,

Vinod

Hello Experts,

I am Displaying itab With checkbox.

In MY itab 150 rows and every Row has a checkBox, I am Using Reuse_Alv_Grid_display.

First user filter the itab with matkl , Then he got 15 row.

The User Requirement is How They Can Selected Multiple Rows(select all)(15 rows) at 1 time , Means Every Check box checked .

Thanks.

Regards: Heman(A1).

3 REPLIES 3
Read only

Sandeep_Panghal
Product and Topic Expert
Product and Topic Expert
0 Likes
596

add a button in the toolbar.

if user presses this button then mark all the check boxes in one go.

Read only

former_member194669
Active Contributor
0 Likes
596

You can do this by

placing a application toolbar (Using PF-status) and once user clicks the application button in the callback user-command you need to fill the lines check box with X and after don't forget to use refresh = 'X'

like


FORM f_user_command USING p_ucomm    LIKE sy-ucomm
                          p_selfield TYPE slis_selfield .
    WHEN '&CHK'.
      perform f_checkbox_select. " write your code for checking checkboxes as X here
      p_selfield-refresh = 'X'.  "<<<----- refresh the grid

Read only

rvinod1982
Contributor
0 Likes
597

Hi Hemat,

First define gd_layout TYPE slis_layout_alv.

Then set property gd_layout-box_fieldname = 'Checkbox fieldname'.

It is not required to create the fieldcatalog for the checkbox field and display the checkbox field separately.

Then the user can select all the rows by just clicking the green color icon in the grid or by using F5 function key.

Regards,

Vinod