Skip to Content
-1

Hiding custom tab in ME51N

Hi,

I have added a custom tab in ME51N with a single field using the exit MEREQ001 .

However, I am unable to hide the custom tab based on conditions. Is there any way it can be achieved ?

I tried hiding it by deactivating the field in the tab, but it does not work.

Any inputs on this please?

Regards,

Vasuki

Add comment
10|10000 characters needed characters exceeded

  • Get RSS Feed

2 Answers

  • Mar 29 at 07:58 AM

    Hello,

    Yes, it is possible using the Framework object (CL_FRAMEWORK_MM).

    First of all, you have to get the framework instance:

    cl_framework_mm=>get_instance(
      importing
        ex_instance = data(framework) ).

    Then, get the view identified by its dynpro number (which I do not remember) and the program:

    framework->get_view(
      exporting
        im_prog  = 'SAPLMEGUI'
        im_dynnr = '<dynnr>'
      importing
        ex_view  = data(custom_view) ).

    You could then hide/unhide the custom tab (view) by calling methods deactivate( )/activate( ).


    Best regards,

    Nicolas

    Add comment
    10|10000 characters needed characters exceeded

  • Apr 02 at 08:54 AM

    Hi Nicolas,

    Where should this be called and I do not find any methods to Deactivate/activate. Can you please let me know.

    Regards,

    Vasuki

    Add comment
    10|10000 characters needed characters exceeded