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: 

cl_bus_tabstrip_tab - set_caption

Koja78
Participant
0 Kudos

The set_caption method of cl_bus_tabstrip_tab of tabs integrated in a cl_bus_tabstrip tabstrip... doesn't seem to work.

Anybody has some experience with this?

Current code:

DATA: mr_tabstrip TYPE REF TO cl_bus_tabstrip.

CLASS-DATA: ms_tabstrip TYPE bus_screen_tabstrip.

IF mr_tabstrip IS NOT BOUND.

CALL METHOD add_tabstrip

EXPORTING

iv_field_name_prefix = 'LCL_TAB=>MS_TABSTRIP'

iv_function_code_prefix = 'FKT'

IMPORTING

ev_tabstrip = mr_tabstrip

CHANGING

cs_tabstrip_control = tabstrip_0500

cs_tabstrip_fields = lcl_tab=>ms_tabstrip.

DATA: lr_tab TYPE REF TO cl_bus_tabstrip_tab,

ls_area TYPE bus_screen_area.

CALL METHOD e_tabstrip->add_tab

IMPORTING

ev_tab = lr_tab.

ls_area-program_name = sy-repid.

ls_area-dynpro_number = e_dynpro.

lr_tab->set_area( ls_area ).

lr_tab->set_caption( 'test' ).

But when the screen displays.. captions are still empty.....

2 REPLIES 2

Koja78
Participant
0 Kudos

Did it by changing captions in lcl_tab=>ms_tabstrip... but that is probably not how it should work.

Former Member
0 Kudos

Hi,

I have got this method working correctly, tab name (pushbutton) name should include the screen local class name. For example if the MS_TABSTRIP is in class lcl_2000 then the tab names should be LCL_2000=>MS_TABSTRIP-TAB_01 and LCL_2000=>MS_TABSTRIP-TAB_02 and so on.

Hope this helps if you are still wondering why these methods do not work.

Regards

Raj