Default value at ME21N

Hi
i want account assignment 'K' and item catagory 'D' get default if user selects perticular document type while creating Purchase order. if PO creation date is greater than a perticular date it should be applicable. screen field account assignment and item catagory filled with K and D automatically.

In transaction SE19, if you display the BADI then select menu option goto>sample code>display,   you will be able to drill down on the PROCESS_ITEM method to some SAP supplied sample code.
This includes the definitions and method calls to get the item data:
    DATA: ls_mepoitem TYPE mepoitem.
    ls_mepoitem = im_item->get_data( ).
You then just change relevant fields in structure ls_mepoitem  and call the set_data method to pass the data back
  call method im_item->set_data exporting im_data = ls_mepoitem.
Take care with what you change - SAP does not validate that you have passed back correct / consistant data.
Andrew

Similar Messages

  • How to set default value in ME21N

    Hi all,
    I want to set default value of PO item's price unit to 1000 and make it unchangeable, is it possible? If so, could you please tell me how to do that.
    Thanks in advance!
    Woody

    Dear Woody,
    1) if u want to make any field un-editable then make it Via SHD0
    2) Plz find the below link for Demo SHD0, here we need to make the field as out put only
    [https://www.sdn.sap.com/irj/scn/wiki?path=/display/snippets/transactionVariant-AStepbyStepGuidefor+Creation]
    Plz Provide the link to ur Abaper
    Regards
    kumar

  • Define Default Values for Doc type..

    Hi All.
    I set a default value of "ME21N" TO "S21" at Define Default Values for Document Type.
    But, default document type is not "S21" but "NB" in ME21N
    ( system ver. 710)
    Let me know how to correct it..
    Thank you in advance.
    regards..
    nam

    Hi,
    Could u please confirm whether have u created the document type
    in
    IMG...>MM.....>Purchasing.....>Purchase order...>Define Document Types.
    if not please do it.
    and then create the pO.
    I think it will work
    Regards
    Aasif

  • Default Value for Order Type based on Company Code  in ME21N

    Hi,
         Using ME21N, I want to make the PO type defaulted to a certain company code, say for instance Company code  XYZ should have a PO type XYZ Purchase Order, ..company ABC should have a PO type ABC Purchase Order, and so on...I'm just puzzled how to implement it. I know that we can set a Default value for PO Headers in Personal Settings but its doesnt give the result I want coz it will only have one Default Value. What I wanted is when a certain company code is chosen, automatically, the corresponding PO type for that Company code will be displayed in the Order Type drop-down menu (so there's no need to choose on the drop down list what Order type) Is this possible in ABAP? Hope i made myself clear.
        Thanks in Advance.

    Use BADI IF IF_EX_ME_PROCESS_PO_CUST - method OPEN
    View the interface documentation in transaction SE19 and you will see the method OPEN can be used :
    2. Opening of a purchase order (OPEN method)
    The system opens a new document to create, change or display a purchase order. With the OPEN method,
    <b>you can import your own data and prepare it for further processing.</b>
    This is available in 4.7 Enterprise but not sure how far back.....
    hope this helps
    Colin.

  • Need to set default values for the fields plant and location in ME21N

    Hi All,
    i need to set default values for the fields plant and location in ME21N tcode.
    In accout assignment if we give 'A' then we need to create asset by clicking the Asset tab,there you have the fields plant and location.
    How to resolve this?
    Thanks in Advance

    hi .
    i needed to set default strorage location and plant in personal setting  in me21n.
    i solve it with this way.
    go to program SAPLMEPERS in se38.
    create new function in output with the sample name :MODULE ZTEST_001 OUTPUT.
    in this module write:
    if MEPOITEM_PROP-WERKS is INITIAL and  MEPOITEM_PROP-LGORT is INITIAL.
    MEPOITEM_PROP-WERKS = '1000'.
    MEPOITEM_PROP-LGORT = '0032'.
    endif.
    this is the solution.
    best regards.
    maryam

  • How to set a default value in the "Our reference"-field in purchse orders?

    Hi!
    When creating a purchase order the "Our reference"-field in the Communication-tab is empty. Is it possible to configure this so that the field is filled by default with the name of the person who is creating the PO?

    Hi,
    There is a button named Personal Settings on ME21N screen. Click on that button --> Click on second tab of Default Values --> Click on More fields --> Select Our reference and maintain the default value. This will always come up at the time of creation of PO.
    Hope this serves the purpose.
    Thanks...
    Edited by: vilas amrutkar on Feb 17, 2009 5:17 AM

  • Default Values for Creation of STO's.

    Hello Experts:
    When I create STO's, I don't see any source of default values, like Delivery Tolerance, Confirmation control key, etc, that for a PO usually come from the Vendor or The Info Record.
    We have managed to add these values via BADI, but for STo's created from APO via Transportation load Builder, this Badi is no taking effect. (The Badi I used is and works fine when doing it online, in ME21N or via a BAPI.
    Do you have any experience on where (user exit, etc) to add logic for putting these default values in the STO's created by TLB.
    Thanks in advance

    Sorry the BADI used is ME_PROCESS_PO_CUST

  • Default values for confirmation control key

    Dear forum
    I am using a confirmation control key 0004 Shipping notification (standard SAP) in the Purchase order line item (created with ME21n).
    When I enter the confirmation data (with transaction ME22n) in the purchase order line item (confirmations tab), I have to type in delivery date, quantity and so on manually, which is standard.
    But, what if I want to copy the original delivery date and quantity from the line item in the order, and use this as default value for the line item confirmation data...is it possible somehow?
    The reason why I want to do this is for the user not having to go in and update this date manually all the time, but only when the confirmed dates/quantities differ from the desired delivery date and quantities in the purchase order line item. We are not on EDI or using Inbound deliverys for Purchase orders.
    Thanks
    Ola

    Hi,
    The Confirmation is nothing but the acknowledgement.So, its usually entered manuallly by the authorised User allowing follow on documents for Purchase Order.
    You can chesk once the customisation of Confiramtion control keys for automatic update indicator.
    Yes, you can use User Exit and develop with the help of ABAPERS.
    Hope it will help you.
    Regards,
    Smitha

  • Default values while creating PO

    Hi Experts,
    There are ceratin fields which can be defaulted at item as well as header level in purchase order.
    Now please guide me that is there any possibilty to add any field apart from the list of fields given by default.
    If yes then please suggest the way.
    rgds

    In the Personal Settings button in the PO entry screen in transaction ME21N, a new window pops up. This window has two tabs: Basic settings and Default values.
    The Default values screen itself has two tabs: PO header and PO item. When you click on the PO header tab (Figure 1), the system displays PO header fields such as Document Type, Purchasing Org., Purch. group, and Company Code. You can set a default value by selecting the desired value from the respective drop-down menus. The advantage of setting defaults here is that these are applicable only to POs and not to every transaction. Once you save these defaults, the corresponding fields are populated with these default values each time you run this transaction.
    This will help you in setting default values to fields at header and item level.
    -Hari.

  • Addition of field in personal setting-default value-po item

    Hi,
    can any one tell me how to incorporate following senario while executing  me21n tcode
    I want to add  a new field “Shipping Instructions” EKPO-EVERS in the personal setting – Default Value – PO Item.
    please tell me the steps to do so
    thanks

    Hi
    please refer to this
    <b>New tabs in the header tab-sheet of ME21N/ME22N/ME23N

  • Dafult Values in Me21n ( Personal Settings)

    Dear All,
    In the personal settings of ME21N at PO item level I want to add the Reminder level 1, 2 & 3 as default value ( i.e 1 level as 3 , 2nd level as 4 & 3rd level as 6 )
    I know it comes from INFO records & inabsence of info records it comes from material master purchasing value keys but when ever i open the screen of ME21N, buyer should get the reminder level fixed as a default.
    Is it possible? If yes could u pl. help me out by telling me how to do it.
    Thanks in adavnce.
    Shailesh

    > In the personal settings of ME21N at PO item level I want to add the Reminder level 1, 2 & 3 as default value ( i.e 1 level as 3 , 2nd level as 4 & 3rd level as 6 )
    The Reminder Levels Cannot be set as Default in Purchase Order Since either they can be Pulled from Purchase Info Record or Material Master.
    The Best Possible Solution is Update the Material Master Purchase Value key to all Material Master Records / Purchase Info Records.
    I dont think it is Possible thru SHD0 Transaction Variant Also.

  • CJ20N Default values

    Hi Friends,
    The user maintained the USER DEFAULT VALUES through  the functional  module u2018CO_IU_TPMUS_SCREENu2019
    Here the user maintain the values  requisitioner,  goods recipient  and purchase group.
    Now they are executing the transaction code CJ20N and here they chose the templates and service here by default values  appeared  except the purchase group.
    So kindly guide me how to get the purchase group values in default.
    Thanks in advance
    Rajendran

    Nitin,
    I do agree with you
    If you go to ME21n or Me51n you will find tab called personal settings similar kind of functinality user is looking for Cj20n Trasaction. As I understand it is not there in PS at transaction level.
    But, the objective is to default the values for those fields and this can be achieved by Screen variants, as I have tested this in my system.
    Ramesh,
    I have tried PIDs as suggested by you but its not working in CJ20N/CN21/CN22/CJ01/CJ02.
    Praveen

  • Default Value is not getting displayed in SUN ONE Ldap

    Hello,
    I have created an attribute in slapd.user_at.conf and it is associated in slapd.user_oc.conf.
    The attribute default value is given through SUN ONE Console. But, In our application the default value is not getting displayed.
    We need the default value to run our applicatin. Can anyone help me for this issue
    Regards,
    K. Senthil Kumar

    Hi anandkumar,
    I belive this issue can be resolved by changing the  Query proprties for the perticular field.
    Kindly check the Field proerties in query designer and ensure that Text is enabled ather than Key.
    __Field property check up:__Go to query designer->click onn the field-> Right hand side in properties click on display tab-> select Text in drop down menu of Display as tab.
    FURTHER CHECK UP: check the master data avaiulability for the perticular info object, if masterdata is not available, do the text data for txt data availability in report level.
    Hope this helps you!!
    Best Regards,
    Maruthi

  • How to load a default value in to a column when using sql loader

    Im trying to load from a flat file using sql loader.
    for 1 column i need to update using a default value
    how to go about this?

    Hi!
    try this code --
    LOAD DATA
       INFILE 'sample.dat'
       REPLACE
       INTO TABLE emp
       empno   POSITION(01:04) INTEGER EXTERNAL NULLIF empno=BLANKS,
       ename   POSITION(06:15)  CHAR,
       job         POSITION(17:25)  CHAR,
       mgr       POSITION(27:30)  INTEGER EXTERNAL NULLIF mgr=BLANKS,
       sal        POSITION(32:39)  DECIMAL EXTERNAL NULLIF sal=BLANKS,
       comm   POSITION(41:48)  DECIMAL EXTERNAL DEFAULTIF comm = 100,
       deptno  POSITION(50:51)  INTEGER EXTERNAL NULLIF deptno=BLANKS,
       hiredate POSITION(52:62) CONSTANT SYSDATE
      )-hope this will solve ur purpose.
    Regards.
    Satyaki De.

  • Assigning a default value to a field

    Hello Everyone,
           Could you please tell me how to assign a default value to a field in a transparent table, so that while creating an entry even if we don't enter the value, a default value will be assigned.
    Thanks,
    Anbu.

    Like this
    DATA: BEGIN OF itab OCCURS 0,
            field1 TYPE c VALUE 'X'
            field2 TYPE c,
          END OF itab.
    append itab.
    append itab.
    You will have by default X set in both rows for field1.
    Regards
    Marcin
    PS: Ooops I just noticed you meant transparent table but I wrote about internal one. As long as you maintain that table using maintenance view you can use event 05 - When Creating a New Entry and set fixed value for a field there. So whenever you create new entry it will receive that value.
    Edited by: Marcin Pciak on Jun 23, 2010 8:57 AM

Maybe you are looking for