PO header on ME21N

hi everyone
is there an enhancement or user exit where we can keep the PO header(the screen which contains the Address tab page, the Org. Data tab page etc) open, like for example we can disable the button which is clicked to open the PO header.

Hi,
What i have found is if you once expand the header and leave the transaction, Then when you come back the previous setting( expanded/collapsed) will be retained.
ie if you expand before leaving the tcode and then come again it will be remain expanded, and if you collapse it before leaving then it will remain collapsed the next time you opens the tcode.
Check whether its working for you, iam on ECC 6.0.
Regards
Karthik D

Similar Messages

  • Additional fields in header of me21n

    which badi to use to add a tab and additional fields in header of me21n.

    Hi,
       check the following badi
       ME_GUI_PO_CUST
    AWARD POINTS IF IT HELPS

  • Want to grey out (Non-editable)  field in Additional Tab in Header of ME21N

    Hi all,
    i've got a requirement to grey out the field(Non Editable) of header tab in ME21N.
    Can anybody tel me the solutions.
    Rgds,
    Spandan

    Question asked again, and again, and again, and again. Search for "grey out" (and please read forum rules as it seems you didn't)

  • Help me on PO Header of ME21N

    hi frnds,
    i need to add one custom field (total qty)in me21n header. for this i used enhancement MM06E005. in this i have added a field in include tables CI_EKKODB and in screen exist SAPMM06E # 0101. now this field is coming on me21n. now my requirement is i need to add all the items qty and i need place that total qty in this field.
    can any 1 help on this.
    points will be rewarded for helpful answers.
    regards,
    balu

    hi sarath,
    thru customer exit i have placed the field on screen.
    but thru badi i am trying to get the value. this code i have placed in Z_ME_PROCESS_PO_CUST -> PROCESS_ITEM.
    here LTSNR is updating but ZZPRADH is not updating. my doubt is, it is updating only system defined fields. it is not updating customer defined fields.
    l_idata = im_item->get_data( ).
    l_idata-ltsnr = l_hdata-zzltsnr.
    SELECT SINGLE prdha INTO t_prdha FROM mara
    WHERE matnr EQ l_idata-matnr.
    IF sy-subrc EQ 0.
    l_idata-zzpradh = t_prdha.
    ENDIF.
    CALL METHOD im_item->set_data
    EXPORTING
    im_data = l_idata.
    after this the value is going in l_data. but in screen only LTSNR is displaying, ZZPRADH is not displaying.
    regards,
    balu

  • ME21N Copy header Z delivery date on to item level

    Dear Friends,
    We add one field for expected date of arrival in header of ME21n.
    My requirement is whenever we put this value and press enter it should reflect
    item level delivery date .
    How can we achive this thing.
    Any help will be highly Appricated.
    Regards
    Naeem

    Hi
    Try implementing BADI ME_PROCESS_PO_CUST use PROCESS_ITEM.
      data : ls_mepoitem type mepoitem. "Purchase Order
      data :ls_header type ref to if_purchase_order_mm,
    ls_data_header type mepoheader.
    ls_header = im_item->get_header( ).
      ls_data_header = ls_header->get_data( ).
    ls_mepoitem = im_item->get_data( ).
      ls_mepoitem-eindt = ls_data_header-zeindt.
    im_item->set_data( ls_mepoitem )
    Shiva

  • ME21N Custom Field in Document Header.

    Hi Guys,
    Could you guys please help me with the following problem.
    I have a custom field in a custom tab in the header of ME21N. But When I change that field manually the transaction does not update the pricing. But if I change any standard field, the transacction update the pricing.
    Do you have any Idea why and how to solve this ?
    Thank you very much.

    Hi , Thanks for your answer Raymond.   But now I have the answer. Let's pretend that I want to insert a new field in EKKO . the field is ZZPUERTO and i want the transaction recalculate the price if i change that field.
    1-. the first thing that you need is to create a copy of this function group MEPOBADIEX. There you have to create your new screen. Comment all the code in all function modules.  Use function module ZMEPOBADIEX_PUSH. Insert there your code. for example:
      zmepo_badi_struct = im_dynp_data.
    2-. Use ME_GUI_PO_CUST and populate method suscribe with the data from the screen that you just create in the first step. in the following way :
    Method: Suscribe
    CHECK im_application = 'PO'.
       CHECK im_element     = 'HEADER'.
    * each line in re_subscribers generates a subscreen.
    *    We add one subscreen in this example
       CLEAR re_subscribers[].
    * the name is a unique identifier for the subscreen and
    *  defined in this class definition
       ls_subscriber-name = subscreen1.
    * the dynpro number to use
       ls_subscriber-dynpro = '9000'.
    * the program where the dynpro can be found
       ls_subscriber-program = 'SAPLZMEPOBADIEX'.
    * each subscreen needs his own DDIC-Structure
       ls_subscriber-struct_name = 'ZMEPO_BADI_STRUCT'.
    * a label can be defined
       ls_subscriber-label = text-001.
    * the position within the tabstrib can be defined
       ls_subscriber-position = 13.
    * the height of the screen can be defined here.
    *  Currently we suport two screen sizes:
    * value <= 7 a sevel line subscreen
    * value > 7  a 16 line subscreen
       ls_subscriber-height = 7.
       APPEND ls_subscriber TO re_subscribers.
    3-. populate the following code in method MAP_DYNPRO_FIELDS
    FIELD-SYMBOLS: <mapping> LIKE LINE OF ch_mapping.
       CONSTANTS: mmmfd_cust_01 TYPE mmpur_metafield VALUE 90000000.
       LOOP AT ch_mapping ASSIGNING <mapping>.
         CASE <mapping>-fieldname.
           WHEN 'ZZPUERTO'.
             <mapping>-metafield = mmmfd_cust_01.
         ENDCASE.
    4-. The followin Code for the method TRANSPORT FROM MODEL
    transport_from_model
    DATA: l_header       TYPE REF TO if_purchase_order_mm,
             ls_mepoheader  TYPE mepoheader,
             ls_customer    TYPE zmepo_badi_struct.
    * system asks to transport data from the business
    *  logic into the view.
       CASE im_name.
         WHEN subscreen1.
    * is it an item? im_model can be header or item.
           mmpur_dynamic_cast l_header im_model.
           CHECK NOT l_header IS INITIAL.
    * transport standard fields
           ls_mepoheader = l_header->get_data( ).
    *      ls_customer-zzpuerto = ls_mepoheader-zzpuerto.
    * store info for later use
    *      MOVE-CORRESPONDING ls_mepoheader TO dynp_data_pbo.
           MOVE ls_mepoheader-zzpuerto TO dynp_data_pbo-zzpuerto.
         WHEN OTHERS.
       ENDCASE.
    5-. Method TRANSPORT_TO_DYNP
    CASE im_name.
         WHEN subscreen1.
           CALL FUNCTION 'ZMEPOBADIEX_PUSH'
             EXPORTING
               im_dynp_data = dynp_data_pbo.
         WHEN OTHERS.
       ENDCASE.
    6-. Method : TRANSPORT_FROM_DYNP
    CASE im_name.
         WHEN subscreen1.
           CALL FUNCTION 'ZMEPOBADIEX_POP'
             IMPORTING
               ex_dynp_data = dynp_data_pai.
           IF dynp_data_pai NE dynp_data_pbo.
             re_changed = mmpur_yes.
           ENDIF.
         WHEN OTHERS.
       ENDCASE.
    7-.  METHOD TRANSPORT_TO_MODEL
    DATA: l_header       TYPE REF TO if_purchase_order_mm,
             ls_mepoheader  TYPE mepoheader.
    * data have to be transported to business logic
       CASE im_name.
         WHEN subscreen1.
    * is it an item? im_model can be header or item.
           mmpur_dynamic_cast l_header im_model.
           CHECK NOT l_header IS INITIAL.
           ls_mepoheader = l_header->get_data( ).
    * customer fields changed?
           IF dynp_data_pbo-zzpuerto NE dynp_data_pai-zzpuerto.
    * update customerfields
             ls_mepoheader-zzpuerto = dynp_data_pai-zzpuerto.
             CALL METHOD l_header->set_data( ls_mepoheader ).
           ENDIF.
         WHEN OTHERS.
       ENDCASE.
    8-. Now we go to BADI ME_PROCESS_PO_CUST and we insert the next code in method FIELDSELECTION_HEADER. This is to show the screen in transactions. 
    DATA: l_persistent TYPE mmpur_bool.
       FIELD-SYMBOLS: <fs> LIKE LINE OF ch_fieldselection.
       READ TABLE ch_fieldselection ASSIGNING <fs>
         WITH TABLE KEY metafield = mmmfd_cust_01.
       IF sy-subrc IS INITIAL.
         CASE sy-tcode.
           WHEN 'ME21N' OR 'ME22N' OR 'ME29N'.
             <fs>-fieldstatus = '.'. " Modify
           WHEN OTHERS.
             <fs>-fieldstatus = '*'. " Display
         ENDCASE.
       ENDIF.
    9-. Finally we go to Method PROCESS_HEADER and there we put the logic that we want for our new screen. For example I put the following code because if the user don't populate the new field I want to use some querys to populate it .
    DATA: ls_mepoheader TYPE mepoheader,
             lv_adrnr      TYPE adrnr,
             lv_adrc       TYPE ad_addrnum,
             lv_transpzone TYPE lzone.
       ls_mepoheader = im_header->get_data( ).
       IF im_header->is_persistent( ) EQ mmpur_no.
         IF ls_mepoheader-zzpuerto IS INITIAL.
           mmpur_metafield mmmfd_cust_01.
           SELECT SINGLE adrnr
           INTO lv_adrnr
           FROM lfa1
           WHERE lifnr = ls_mepoheader-lifnr.
           IF sy-subrc EQ 0.
             lv_adrc = lv_adrnr.
             SELECT SINGLE transpzone
             INTO lv_transpzone
             FROM adrc
             WHERE addrnumber = lv_adrc.
             IF sy-subrc EQ 0.
               ls_mepoheader-zzpuerto = lv_transpzone.
               CALL METHOD im_header->set_data( ls_mepoheader ).
               CLEAR ls_mepoheader.
             ENDIF.
           ENDIF.
         ENDIF.
       ENDIF.
    10. Any questions please let me know. I know it is difficult but it works.
    Thanks .

  • Enhancement for me21n New tab

    Dear Sdn'ers
    I am facing a problem while updating the data from newly created tab in header for ME21N . Let me clarify I have designed the screen for adding the tab in header of me21n . Tab is diplay is over but New field added is not updated while in debugging.
    badi : ME_GUI_PO_CUST
    Method : IF_EX_ME_GUI_PO_CUST~TRANSPORT_FROM_DYNP
    break-point.
    CASE IM_NAME.
        WHEN SUBSCREEN1.
          CALL FUNCTION 'ZMEPOBADIEX_POP'
            IMPORTING
              EX_DYNP_DATA = DYNP_DATA_PAI.             "
          IF DYNP_DATA_PAI NE DYNP_DATA_PBO.
    something has changed therefor we have to notify the framework
    to transport data to the model
            RE_CHANGED = MMPUR_YES.
          ENDIF.
        WHEN OTHERS.
    Regards
    Pradeep
      ENDCASE.

    DONE THROUGH USER EXIT

  • Save custom fields value  in EKKO through ME21N

    Hello Friends,
    putting a new inputfield in the header of ME21N - PO transaction must be inserted within existing tabstrib "Additional Data".
    This the new requirement.
    I have used the enhancement "MM06E005". I have only implemented and activated the USEREXIT without writing
    any code in any Function Module.
    Additionally I have added through the screen painter (Function Pool MEGUI) into screen 1229 the customer
    ZFIELD (Textinputfield).
    I can see this field in the transaction ME21N, ME22N, ME23N but if I enter any value and save it. This Field has only 0000000 in the EKKO instaed of the entered value by me.
    In the other transaction like ME21 ME22 ME23 this problem is not existing. I can save the enterd date without any problem.
    I have already implemented the structure CI_EKKODB too. There is the zcustom field added.
    I need your  help for in how to save the data in EKKO with me21n.
    Kindly Regards
    Marco

    Dear Marco,
    Dont use User Exit for this . Use the BADI's .If uses the USer Exit it will create u some probs at later stage.
    There are 2 BADI's available for this.
    1) ME_PROCESS_PO_CUST.
    2) ME_GUI_PO_CUST.
    1) ME_PROCESS_PO_CUST.This BADI is for Validating the PO at various Level. Methods for this BADI is
    1.Open.
    2.Initialize.
    3.Process Header.
    4.Process Item.
    5.Check.
    6.Post.
    Etc.
    So u can Validate the Entire PO ..
    2. ME_GUI_PO_CUST.
    Adding the Customer Own Screen to Enjoy Purchase Order.
    The Process is that Just Create a Function Group with the Screen with Screen Which u want to Add to the Header Level.
    Through this BADI u can add N Number of Screen to PO.
    In the First Method of this BADI just Add the Screen. For Better Understanding goto the Sample Coding of Both BADI's.
    With Regards,
    Sumodh.P

  • Raisiing an error message to fill in customised tabscreen in me21n

    hi.
    i have created one tabscreen in header of me21n and i just want to raise an error message if the use has filled data in all t fields of tabscreens of header in me21n except the customised tabsubscreen that i have created .
    i came to know that this could be possible through process header,check methods of me_process_po_cust but i dont know of which one to prefer.
    please provide me the code with method as well.
    u r anser would be appreciated.
    bye.
    regards.
    sita.

    Transaction Code - ME51N Create Purchase Requisition
    Exit Name Description
    MEREQ001 Customers' Own Data in Purchase Requisition
    No of Exits: 1
    USER EXIT
    http://www.sap-img.com/abap/a-short-tutorial-on-user-exits.htm
    http://www.sap-img.com/abap/what-is-user-exits.htm
    http://expertanswercenter.techtarget.com/eac/knowledgebaseAnswer/0,295199,sid63_gci982756,00.html
    Minal

  • Add Validity Start and Validity End On PO Header

    Dear SAP,
    need your help, I am trying to add Validity Start and Validity End Field on Additional Tab in Purchase Order header.
    How do i add this field ?
    i already check on MM define screen layout a document level, but there is not setting for this two field.

    Hi Nizam,
    The validity start date & end date are used only for service orders. In configuration goto IMG>MM>Purchasing>PO>Define screen layout at document level and check into Administrative data, header of ME21N , the field selection key attached to your document type (Say NBF) and for field selection key AKTH.
    The fields Start of validity period & Validity period end of field selection key ME21N, NBF & AKTH should be set as optional then only required fields will be visible on screen.

  • Use of SAVE_TEXT in customer exits / BADI for purchase order

    Hi All,
    I am trying to save some long text by using SAVE_TEXT function module in a badi implementation for purchase order header text. The same is working fine if i try to update the PO header text via a report. But if i try using badi (the code is written in a PAI event for the BADI), then though the text transfer and save is successful during the code excution, but for the first time when i add any text its not visible in ME22N tcode. Since its an online event. But when i double click on that editor and the sap script editor gets opened. then i press back button, the text is appearing on the same small screen edtor . after this any number of time i edit or delete text, the save_text function module works fine.
    My issue is why for the first time always i have to double click on the editor to open the sap script editor. I have also included commit_text in this case after save_text FM.
    the requirement here goes like this. in one tab for PO header the user will enter some number (This is a customizing screen implemented through badi.) and the corresponsing discription should appear when user clicks on text tab in po header screen (me21n / me22n).
    Kindly help.
    Thanks
    Mamata

    Hi  mamata rath
    I have solve the problem which similar to yours.  the code which is as the following
    DATA: textline TYPE tdline,
            name TYPE c LENGTH 70,
            glines TYPE TABLE OF tline,
            gline  LIKE LINE OF glines,
            ls_header TYPE thead.
         CONCATENATE ch_eban-banfn ch_eban-bnfpo INTO name.
             ls_header-tdobject = 'EBAN'.
             ls_header-tdname = name.
             ls_header-tdid = 'B01'.
             ls_header-tdspras = sy-langu.
             CALL FUNCTION 'SAVE_TEXT'
               EXPORTING
    *           CLIENT                = SY-MANDT
                 header                = ls_header
    *           INSERT                = ' '
    *           SAVEMODE_DIRECT       = ' '
    *           OWNER_SPECIFIED       = ' '
    *           LOCAL_CAT             = ' '
    *         IMPORTING
    *           FUNCTION              =
    *           NEWHEADER             =
               tables
                 lines                 = glines
               EXCEPTIONS
                 ID                    = 1
                 LANGUAGE              = 2
                 NAME                  = 3
                 OBJECT                = 4
                 OTHERS                = 5
              IF sy-subrc = 0.
                  CALL FUNCTION 'COMMIT_TEXT'
                    EXPORTING
                      OBJECT                = 'EBAN'
                      NAME                  = name
    *                ID                    = '*'
    *                LANGUAGE              = '*'
    *                SAVEMODE_DIRECT       = ' '
    *                KEEP                  = ' '
    *                LOCAL_CAT             = ' '
    *              IMPORTING
    *                COMMIT_COUNT          =
    *              TABLES
    *                T_OBJECT              =
    *                T_NAME                =
    *                T_ID                  =
    *                T_LANGUAGE            =
              ENDIF.

  • Exchange rate in PO, MIGO & MIRO

    Hi all,
    I would like to understand clearly how exchange rate will be taken.
    My scenario:
    Our company currency is EUR. Creating PO for a foreign vendor of USD. Exchange rate is picked by default. I have selected "Exchange rate fixed" indicator. But in MIGO it has taken some other rate may be based on the current date.
    In MIRO for Goods items it is taking the rate shown in PO and it is greyed out. This is as expected.
    But while doing MIRO for planned delivery costs also system is behaving like in case of MIGO. it is fetching the exchange rate as on today from table & not from PO.
    One more question: I have not maintained the rate for USD to EUR in OB08 either Direct or indirect quote. but how the system is calculating, I dont understand.
    The requirement is that system should take same rate as PO at all places.
    Please help me.
    Thanks in advance
    Nagesh

    OB08 is a master data from where the exchange rate is picked up for ME21n , If ur company code currency is EUR then exchange rate type su\ystem will pick will be EURX
    there is a indicator fixed near exchang rate in header in Me21n, u can change the exchange rate in Me21n or keep as it is and fix the indactor as fixed
    If u do this than the exchange rate will have preferance at the time of MIGO and MIRO even if u change the exchange rate in OB08
    and if u dont put on the indicator then system will not take the exchange rate from PO at the time of MIGO and MIRO, but it will take for OB08.
    IF u have put the Exchange reate fixed incdactor than system should pick rate from PO only in MIGO or MIRO. U can check the cycle once more with Exchange rate indicator for Fixed keeping it on
    thankx

  • Set condition of payment to '0000' if document type = ZDOC

    Hello,
    i have to set the condition of payment in the Delivery header( transaction ME21N) to '0000' by default if the document type ='ZDOC' . therefore the condition of payment defined in vendor master will not be taken.

    hi u have to write a requirement in VOFM
    http://saptechsolutions.com/pdf/VOFMCopyRequirementRoutines.pdf
    http://saptechsolutions.com/pdf/InsideVOFM.pdf
    regards
    kunal

  • Badi and user exit active at the same time ?

    Hi All,
    Please let me know whether
    1> I can have a BADI and a user exit both active at the same time for the same enhancement?
    2> I can have a BADI and a user exit both active at the same time but they are for different purpose.
        eg: BADI       -- > to change statistical date of po item line on ME21N screen
              User Exit -- > to change the exchange rate on PO header on me21n screen
    Please response to the second point... as this is what I am working on.
    Regards,
    Shital

    Hello,
    Thanks for your response.This is my code.
                             WSA_header = IM_HEADER->GET_DATA( ).
                              wsa_header-wkurs = '0.6668'.
                           CALL METHOD im_header->set_data
                                EXPORTING
                                       im_data = wsa_header.
    Kind Regards,
    Shital

  • Screen Exit ME22N

    Hi Friends,
      I have created the custom tab at PO header level (ME21N) and designed the required fields in the screen SE51.
    But my problem is how to populate these amount values in the custom screen.
    Example:
    Screen Name : SD
    Screen Field: ZSDSUB which is not available in EKKO table.
    Screen Description: SD Deposit%

    Are you using the BADI ME_GUI_PO_CUST for that.
    if so there are various methods to do that.
    TRANSPORT_TO_DYNP  "To the screen
    TRANSPORT_FROM_DYNP " From the screen
    I hope you are not using the BADI.

Maybe you are looking for

  • Using Same Menus with Revised Source Movie?

    My prediction on this question is that the only answer will be: Recreate From Scratch. But just to further my education, here goes... I have an iDVD project which I've got set up and working nicely from the DVD authoring standpoint. Menus and buttons

  • Preventing empty rows in address formats

    Hallo everyone! I'd like to know if there is a method to prevent SBO2005A from printing empty rows in the address fields when for instance there is missing county in BP addresses like this: I have defined an address format that goes Block County Stre

  • Non blocking socket: GUI hangs

    Hello, i have made a swing based GUI. It sends a request to the local server and the server keep sending response to it. Basically request is sent once, but response is in the form of stream. But my problem is that GUI hangs after getting the respons

  • Windows 7 and Wireless Mighty Mouse, Wireless Keyboard and sound problem

    Hi, I just installed Windows 7 x64 Ultimate on my iMac 24" white ( OS X Leopard 10.5 ). Surprisingly, it installed without any problems. The only problems I have now are the Wireless Mighty Mouse and the Wireless Keyboard ( alu ). After I installed W

  • JFileChooser functioning like normal Windows Apps FileChooser

    I have this problem that's been giving me too much headache already. When you click on Open on any Windows app, and click on the "Details" button, it will show you the files' details (FileName, Type, Date, etc.). This is the same with JFileChooser, s