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

BCALV_EDIT_0*

Former Member
0 Likes
1,343

Hi experts

I have a requirement to create an editable ALV with Insert, Copy and Update functionality.

I went through the posts and figured that i must look into the BCALV_EDIT_0* standard programs.

What i am still not able to understand is how the ALV tool bar is specified for the grid display.

For example, the tool bar in BCALV_EDIT_03 does not contain the insert, delete or copy buttons. Whereas the tool bar in BCALV_EDIT_02 has these buttons.

How is the tool bar selected and is there any way i can control which tool bar is displayed?

Any help will be greatly appreciated.

Thanks

-Navin

1 ACCEPTED SOLUTION
Read only

rosenberg_eitan
Active Contributor
0 Likes
1,304

Hi,

BCALV_EDIT_03 is using it_toolbar_excluding parameter.

   

Regards.

Hi experts

I have a requirement to create an editable ALV with Insert, Copy and Update functionality.

I went through the posts and figured that i must look into the BCALV_EDIT_0* standard programs.

What i am still not able to understand is how the ALV tool bar is specified for the grid display.

For example, the tool bar in BCALV_EDIT_03 does not contain the insert, delete or copy buttons. Whereas the tool bar in BCALV_EDIT_02 has these buttons.

How is the tool bar selected and is there any way i can control which tool bar is displayed?

Any help will be greatly appreciated.

Thanks

-Navin

5 REPLIES 5
Read only

Former Member
0 Likes
1,303

Hi ,

Following code will enable the editing facility .

IF grid1->is_ready_for_input( ) eq 0.

* set edit enabled cells ready for input

     CALL METHOD grid1->set_ready_for_input

                      EXPORTING i_ready_for_input = 1.


Yes you can control the tool bar  using conditions , put the above code inside condition and you should be good .


Thanks

Manik


Read only

former_member156446
Active Contributor
0 Likes
1,303


in the fieldcatalog if you set ls_fcat-edit = 'X' will also get you the extra buttons.

Read only

rosenberg_eitan
Active Contributor
0 Likes
1,305

Hi,

BCALV_EDIT_03 is using it_toolbar_excluding parameter.

   

Regards.

Read only

0 Likes
1,303

Thanks Eitan... This is what i was looking for

Read only

rosenberg_eitan
Active Contributor
0 Likes
1,303

Hi,

Another mysterious flag is:

DATA: st_layout TYPE lvc_s_layo ,

st_layout-no_rowins  = abap_true ."Block ctrl enter .

  CALL METHOD ob_gui_alv_grid_1->set_table_for_first_display

      EXPORTING

        it_toolbar_excluding = it_toolbar_excluding

        is_layout            = st_layout

        is_print             = st_print

        i_save               = 'A'

        is_variant           = gs_disvariant_1

      CHANGING

        it_sort              = it_sort

        it_fieldcatalog      = it_fieldcatalog

        it_outtab            = it_alv_grid_a.

       

Regards.