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

Remove delete option from button 'Layout' ALV grid

Former Member
0 Likes
1,960

The ALV grid displays the button to change the layout (global/user specific).

The user can create his/her own layout variant or change it. However, I would like to hide/remove the option 'Delete layout' from the possible options.

Is this possible?

Regards,

Henry

1 ACCEPTED SOLUTION
Read only

Former Member
0 Likes
1,196

Hi,

Delete function code of 'Delete' button in the pf status of your alv grid

then you will not get the ''delete' button in your layout

Regards,

anil

The ALV grid displays the button to change the layout (global/user specific).

The user can create his/her own layout variant or change it. However, I would like to hide/remove the option 'Delete layout' from the possible options.

Is this possible?

Regards,

Henry

3 REPLIES 3
Read only

former_member214857
Contributor
0 Likes
1,196

Hello Henry

You can do this creating your own Application Toolbar (PF-STATUS) and set it during ALV Grid creation using parameter

i_callback_pf_status_set. Then you can set your own PF-STATUS for this ALVgrid

Warm Regards

Carlos Machado

Read only

Former Member
0 Likes
1,196

Henry,

Since Layout DELETE button is part of another program, you can't simply exclude it from your ALV grid display.

But, I suppose that layout deletion is possible only from the menu bar using 'Layout Management' and is not possible from the Application toolbar buttons of ALV grid. Also, all other functionalities for layout (new creation, change layout etc ) are possible without using this 'Layout Management' option from menu bar.

So, I think you can meet your requirement hiding the 'Layout Management' option itself simply by excluding it from the grid.

  
 gs_excluding-fcode = '&ERW'.
  APPEND gs_excluding TO gt_excluding.

CALL FUNCTION 'REUSE_ALV_GRID_DISPLAY_LVC'
    EXPORTING
...
      it_excluding                      = gt_excluding
...

BR,

Diwakar

Read only

Former Member
0 Likes
1,197

Hi,

Delete function code of 'Delete' button in the pf status of your alv grid

then you will not get the ''delete' button in your layout

Regards,

anil