Skip to Content

How to hide the tabstrips in webdynpro abap

Hi

I have to hide(none) / unhide (visible) tabstrips dynamically based on data availability.

I wrote the below code to hide.

lo_el_context_b->set_attribute(
name = `BOOLEAN`
value = cl_wd_tab=>set_focus( ' ' ). got error only used with static methods.

data : BOOLEAN type WDUI_VISIBILITY.

How can i achieve this kindly help me.

Regards,

Kiran

Add comment
10|10000 characters needed characters exceeded

  • Get RSS Feed

4 Answers

  • Mar 08, 2017 at 09:06 AM

    Hi,

    You can create an atribute in the context for each tab and bind them with the property visible. You only need to change the value of this atribute dynamically.

    You can also try with this code (Within the WDDOMODIFYVIEW);

    DATA:
    lo_tab TYPE REF TO cl_wd_tab.

    lo_tab ?= view->get_element( 'TAB_1' ).

    CALL METHOD lo_tab->set_visible
    EXPORTING
    value = abap_true. "abap_false

    Add comment
    10|10000 characters needed characters exceeded

  • Mar 09, 2017 at 12:03 PM

    Hi Ricardo,

    I have created attribute(data : BOOLEAN type WDUI_VISIBILITY.) in the context and bind it in all tabs with property visible.and wrote the code as below.but it is not hidden.

    lo_el_context_b->set_attribute(
    name = `BOOLEAN`
    value = cl_wd_tab=>e_visible-none ).

    but still ,it won't work.

    Regards,

    Kiran Jagana.

    Add comment
    10|10000 characters needed characters exceeded

  • Mar 13, 2017 at 12:50 PM

    Hi, Kiran,

    If you want to hide the entire tabstrip you only need to bind the attribute BOOLEAN once with the property visible of the tabstrip, not to all the tabs.

    Use the type WDY_BOOLEAN for the attribute and abap_false instead of cl_wd_tab=>e_visible-none.

    Add comment
    10|10000 characters needed characters exceeded

  • Mar 14, 2017 at 10:42 AM

    Hi Ricardo,

    I want to hide the tabs under tabstrip dynamically.based on the data availability.not entire tabstrip.

    Add comment
    10|10000 characters needed characters exceeded