Skip to Content
avatar image
Former Member

Hiding a button added on XD02 screen when company code is initial


I have added a button "Financial extract" in XD02 .

I added a button in SPRO ,Modification-Free Enhancement in Customer Master Record ,by adding screen group and function code.

Now my requirement is If company code is initial i need to hide my custom button in XD01/XD02??How to do that?

Any suggestions??

Add comment
10|10000 characters needed characters exceeded

  • Get RSS Feed

2 Answers

  • avatar image
    Former Member
    Jul 10, 2009 at 10:37 PM

    When you added a button, there should be some code written in the PAI of that screen.

    Similary a PBO would exist for the screen.

    In the PBO, check if your company code is initial and then check for your screen-group and code something like this:

    if <g_bukrs> is initial.

    loop at screen.

    if screen-group = some name'

    screen-invisible = '1'.

    modify screen.




    hope this helps.



    Add comment
    10|10000 characters needed characters exceeded

    • Former Member Former Member

      you need to find out an user-exit or a badi or an enhancement spot(if you are on ecc6.0). You want to take help of an abaper for this.

      Once you find this, he can place this simple pice of code for you.



  • Jul 11, 2009 at 09:42 AM


    I have worked in the similar requirment it is very simple

    based on your condition ie if company code = space

    add the function code to exclueing table of the PF status table

    to write this pice of code you can use implicit enhancement in the form where set pf status is written.

    Hope this helps.

    If you have any further querry feel free to contect me.



    Add comment
    10|10000 characters needed characters exceeded