Userexit for updating sales order user status based on PO

Hi.
My clients requirent is
Sales order user status should get updated based on production order creation,GR for PO creation etc.
Basically depending on PO & GR For PO,various user stauts in sales order should get updated.
Can you please suggest me some userexits in PP for this requirement?
I am a SD Consultant and not having much idaes about PP
Thanks
Nisha

hi,
if you are not going to update it in the SO..
then you need different exits as those are different transactions.

Similar Messages

  • Userexit for updating sales order user status based on Production Order

    Hi.
    My clients requirent is
    Sales order user status should get updated based on production order creation,GR for PO creation etc.
    Basically depending on PO & GR For PO,various user stauts in sales order should get updated.
    Can you please suggest me some userexits in PP for this requirement?
    I am a SD Consultant and not having much idaes about PP
    Thanks
    Nisha

    hi,
    if you are not going to update it in the SO..
    then you need different exits as those are different transactions.

  • Creating check on officers who can change a sales order - User Status

    The user needs to create a check on persons who can change (User Status) on the sales order created.
    The sales order are created by a group of people. These group of people can not be allowed to change the sales order - User Status(In header Detail).
    Only a second level user users should be allowed change this user status.
    Can it be done at configuration level. Or should we use an Exit?
    Thanks in advance.

    Hi Sunoj,
    I never have used this auth. objects, but if you want to set restrictions on some users, search before in auth. objects. As I told you, you can use the tcode SU24 for this purpose. Do the selection, see the result, try it with tcode PFCG and check it.
    If you can do something with customizing tools or other standard tools (as authoritation tools) avoid the use of enhancements, BADI, BTE'S and so on. If you don't find the solution, then go to userexits.
    I hope this helps you
    Regards
    Eduardo

  • Update order user status based on a custom check box value in web ui

    Hi Experts,
    I have a requirement to Update the  user status based on a custom check box value in web ui.
    This is needed at the followup for a SR, the component is BT116H_SRVO, Details View.
    I created a value node with 4 checkboxes, based on the check box value, the corresponding user status
    need to be updated.
    How can I reach to the order save functionality of SAP in EH_ONSAVE method, so that syatem can capture my check box value, along with other screen fields, and append the status parameter in Order maintain?
    or do I have to call order maintain in even handler for checkbox, which will affect performance .....
    Pls help.
    Regards,
    Lakshmi

    Hi,
    In your event handler you can use bol entity corresponding to status BTStatusH and change the user status.
    Best regards,
    Caíque Escaler

  • Function module for changing Work order user status in IW32

    Hi,
    I want to change the work order user status in IW32 using ABAP.
    Is there any function module to do so or any other way? I have tried using BDC but this does not work.
    Please suggest.
    Regards,
    Naba
    Edited by: n. saha on Nov 5, 2008 6:46 AM

    I am getting Same Problem.
    fi_methods-method = 'SAVE'.
    APPEND fi_methods.
    fi_methods-refnumber = 1.
    fi_methods-objecttype = 'USERSTATUS'.
    fi_methods-method = 'CHANGE'.
    fi_methods-objectkey = '002000002453'.
    APPEND fi_methods.
    fi_userstatus-user_st_text = 'COMM'.
    fi_userstatus-user_langu   = 'EN'.
    fi_userstatus-CHANGE_EVENT = ' 01 '.
    APPEND fi_userstatus.
    CALL FUNCTION 'BAPI_ALM_ORDER_MAINTAIN'
      TABLES
        it_methods    = fi_methods
        it_userstatus = fi_userstatus
        return        = fi_return.
    CALL FUNCTION 'BAPI_TRANSACTION_COMMIT'.
    Above code I am using and there the message comes like
    T ID                   NUM           MESSAGE
    S IW                   080           Order saved with number 2000002453
    S IWO_BAPI2     110           BAPI control was ended
    can any on know what is wrong in this? please help if having knowledge.
    Thank You,
    Jahnavee Trivedi

  • Inbound IDoc used for updating Sales order status

    I have a requirements to set use standard IDoc to send out the Sales order to a non-SAP software as well as receiving Inbound IDoc to update the status of sales order in SAP. Could someone comment on my questions below:
    1. What are the difference between all the ORDERSxx Idoc types?
    2. What IDoc should be used for Inbound IDoc to update the sales order stataus in SAP?
    3. Can the same IDoc type be used for both Inbound and Outbound with only the difference in the segment of Direction?
    Thank you. Points will be awarded appropriately for helpful comments.

    Hi,
      1.Intially  standard IDOC types "ORDERS01"  is having limited
          segments. After few months the requirement got increased to
          add more fields to "ORDERS01".So,once you release the IDOC
          type you can not add any more fields .So SAP come up
          with "ORDERS02" with new fields.Like that all IDocs types have
          some more new seg ments.
    2.You  can use ORDER05
    3. Yes you can use same IDOC type

  • Userexit to update sales order no for packaging material during PGI

    Hi,
    Scenario is like this:-
    1.Sales order will be created for material X
    2.Delivery will take place and packaging of material X will take place.
    3.The packaging material will come as a line item and we do PGI by picking the quantity.
    4.Now when we see the accounting document for PGI,we get the sales order reference for X.
    5.We are not getting the reference of Sales order no for packing material while seeing the accounting document in  PGI.
    6.Since the packing material is not maintained in Sales order thats why the sales order no is not getting updated in the accounting document.
    7.NOW I WANT TO UPDATE THE SALES ORDER FIELD FOR PACKING MATERIAL ALSO ONCE THE PGI IS TAKING PLACE.
    Can any one suggest me if there is any userexit to update the sales order field for accounting document of packing material once PGI happens.
    regards
    Somnath

    Hi,
    Since packging material is not sales order item so it can't be accounted in PGI packging material is aour internal stock and not sellable stock.
    Reward points if helps.
    Thanks & Regards
    Sasikanth.Ch

  • Sales Order User Status

    Hi,
    is there any FM or user-exits to set the User Status of the Sales Order Line Item at the time of Order Creation.
    ( status profile is created with 3 status in BS02 and assigned to the order line item. user exit / fm has to change the status assigned to the order based on certain conditions )
    Lot of FM are available to update the status after Order Creation. I'm lookin for one at the time of order creation where i could use in the exit MV45AFZZ.
    looking for your inputs.
    Thanks,
    Arun

    Thanks, I have gone through this. This needs a Object Number to update the status.
    In my case i wont have the object number at the time of order creation.
    Thats the problem.

  • BAPI for changing Work order user status in IW32

    Hello Experts,
    I am getting Same Problem in updating status via BAPI, BAPI_ALM_ORDER_MAINTAIN.  Its not giving any error but even not update status.
    I know i can use this for changing the user status also but not sure how to carry out things.
    I used this code.
    fi_methods-method = 'SAVE'.
    APPEND fi_methods.
    fi_methods-refnumber = 1.
    fi_methods-objecttype = 'USERSTATUS'.
    fi_methods-method = 'CHANGE'.
    fi_methods-objectkey = '002000002453'.
    APPEND fi_methods.
    fi_userstatus-user_st_text = 'COMM'.
    fi_userstatus-user_langu   = 'EN'.
    fi_userstatus-change_event = ' 01 '.
    APPEND fi_userstatus.
    CALL FUNCTION 'BAPI_ALM_ORDER_MAINTAIN'
      TABLES
        it_methods    = fi_methods
        it_userstatus = fi_userstatus
        return        = fi_return.
    CALL FUNCTION 'BAPI_TRANSACTION_COMMIT'.
    Above code I am using and there the message comes like
    T ID                   NUM           MESSAGE
    S IW                   080           Order saved with number 2000002453
    S IWO_BAPI2     110           BAPI control was ended
    can any on know what is wrong in this? please help if having knowledge.
    Thank You,
    Jahnavee Trivedi

    I am getting Same Problem.
    fi_methods-method = 'SAVE'.
    APPEND fi_methods.
    fi_methods-refnumber = 1.
    fi_methods-objecttype = 'USERSTATUS'.
    fi_methods-method = 'CHANGE'.
    fi_methods-objectkey = '002000002453'.
    APPEND fi_methods.
    fi_userstatus-user_st_text = 'COMM'.
    fi_userstatus-user_langu   = 'EN'.
    fi_userstatus-CHANGE_EVENT = ' 01 '.
    APPEND fi_userstatus.
    CALL FUNCTION 'BAPI_ALM_ORDER_MAINTAIN'
      TABLES
        it_methods    = fi_methods
        it_userstatus = fi_userstatus
        return        = fi_return.
    CALL FUNCTION 'BAPI_TRANSACTION_COMMIT'.
    Above code I am using and there the message comes like
    T ID                   NUM           MESSAGE
    S IW                   080           Order saved with number 2000002453
    S IWO_BAPI2     110           BAPI control was ended
    can any on know what is wrong in this? please help if having knowledge.
    Thank You,
    Jahnavee Trivedi

  • Change sales order user status

    Hello experts,
    I'm trying to update the user status with the following code without success:
    DATA : LIT_STATUS_COMT       TYPE CRMT_STATUS_COMT,
           WA_STATUS_COMT        LIKE LINE OF LIT_STATUS_COMT,
           LIT_FIELD_NAMES       TYPE CRMT_INPUT_FIELD_NAMES_TAB,
           WA_INPUT_FIELD_NAMES  LIKE LINE OF LIT_FIELD_NAMES.
    SELECTION-SCREEN BEGIN OF BLOCK AAA.
    PARAMETERS: P_GUID  TYPE CRMT_STATUS_COM-REF_GUID,
                P_STAT TYPE   CRMT_STATUS_COM-STATUS.
    SELECTION-SCREEN END OF BLOCK AAA.
    CLEAR WA_STATUS_COMT.
    WA_STATUS_COMT-REF_GUID       = P_GUID.
    WA_STATUS_COMT-REF_KIND       = 'A' .
    WA_STATUS_COMT-STATUS         = P_STAT. " Pass the user status
    WA_STATUS_COMT-USER_STAT_PROC = 'ZOR00001'. " Value for the User Status Profile.
    WA_STATUS_COMT-ACTIVATE       = 'X'.
    INSERT WA_STATUS_COMT INTO TABLE LIT_STATUS_COMT.
    WA_INPUT_FIELD_NAMES-FIELDNAME = 'ACTIVATE'.
    APPEND WA_INPUT_FIELD_NAMES TO LIT_FIELD_NAMES.
      CALL FUNCTION 'CRM_STATUS_MAINTAIN_OW'
        EXPORTING
          IT_STATUS_COM        = LIT_STATUS_COMT
        CHANGING
          CT_INPUT_FIELD_NAMES = LIT_FIELD_NAMES
        EXCEPTIONS
          NOT_ALLOWED          = 1
          ERROR_OCCURRED       = 2
          WARNING_OCCURRED     = 3
          OTHERS               = 4.
      DATA: LT_OBJECTS_TO_SAVE  TYPE  CRMT_OBJECT_GUID_TAB,
            LS_OBJECTS_TO_SAVE  LIKE LINE OF LT_OBJECTS_TO_SAVE.
      LS_OBJECTS_TO_SAVE = P_GUID.
      APPEND LS_OBJECTS_TO_SAVE TO LT_OBJECTS_TO_SAVE.
      CALL FUNCTION 'CRM_STATUS_SAVE_OW'
       EXPORTING
         IT_HEADER_GUID           = LT_OBJECTS_TO_SAVE
    best regards,
    Ronen.

    R.R,
    I already tried that without success:
    INCLUDE CRM_STATUS_CON.
    INCLUDE CRM_LOG_STATES_CON.
    SELECTION-SCREEN BEGIN OF BLOCK AAA.
      PARAMETERS: P_OBJNR  TYPE CRM_JSTO-OBJNR,
                  P_STAT TYPE   CRM_JEST-STAT.
      SELECTION-SCREEN END OF BLOCK AAA.
    START-OF-SELECTION.
    CALL FUNCTION 'CRM_STATUS_CHANGE_EXTERN_OW'
      EXPORTING
    *   CHECK_ONLY                = ' '
        OBJNR                     = P_OBJNR
        USER_STATUS               = P_STAT
    *   SET_INACT                 = ' '
    *   IV_REF_KIND               =
    *   IV_OBJECT_TYPE            =
    *   IV_NO_1O_MAINTAIN         =
    * IMPORTING
    *   STONR                     =
    * EXCEPTIONS
    *   OBJECT_NOT_FOUND          = 1
    *   STATUS_INCONSISTENT       = 2
    *   STATUS_NOT_ALLOWED        = 3
    *   OTHERS                    = 4
    IF SY-SUBRC <> 0.
    * MESSAGE ID SY-MSGID TYPE SY-MSGTY NUMBER SY-MSGNO
    *         WITH SY-MSGV1 SY-MSGV2 SY-MSGV3 SY-MSGV4.
    ENDIF.
    CALL FUNCTION 'BAPI_TRANSACTION_COMMIT'
    EXPORTING
       WAIT          = 'X'
    * IMPORTING
    *   RETURN        =
    any other suggestions?
    Ronen.

  • USEREXIT_ADD_FIELD_TO_LINE for updating sales order loading dates

    Hi,
    I have a requirement to update the loading date in the sales order scheduling lines. I am trying to do it in <b>USEREXIT_ADD_FIELD_TO_LINE</b> in program SAPFV45V but there is also a comment in the userexit stating field needs to be added to structure AV03VZ. Is this required? The code seems do fine without using the structure. Also, should I be modifying the include <b>FV45VFZZ_USEREXIT_ADD_FIELD_TO</b> itself or should I do it through CMOD. If so, what would be the enhancement?
    We are in 4.7, it looks like from rel.>4.6, we should be using include <b>FV50XATP_USEREXITS</b> instead, but during debug, the codes in this userexit never get called. Are these two exits doing the same thing?
    Does anybody know which one should a 4.7 systems be using to modify the loading date?
    Thank you,
    Minami

    Found out that we do need to modify the include its own. And the FV50XATP_USEREXITS is being executed when the delivery due list is executed, not when the order is created so in order to influence the loading date in the order, userexit in SAPFV45V needs to be modified.
    Question closed.

  • Idoc segment for updating Sales order item dates

    Hi All,
    I would ike to update the sales order item dates (loading date, Goods Issuance date etc) from an IDOC.
    please let me know the Idoc segment and fields that need to be filled in?
    Thanks in advance.
    Regards,
    Zeeshan.

    Hi,
    Here are some details of the segments in the idocs -
    SEGNAM Segment Name E1EDL20
    VBELN Sales and Distribution Documen 180001539
    SEGNAM Segment Name E1EDL18
    QUALF IDOC Qualifier: Control (Deliv PIC : Picking with flow records (inbound)
    SEGNAM Segment Name E1EDL18
    QUALF IDOC Qualifier: Control (Deliv PGI : Post delivery goods issue (inbound)
    SEGNAM Segment Name E1EDT13
    QUALF IDOC Qualifier: Date (Delivery 010 : Picking
    NTANF Constraint for activity start 20090808
    ISDD Actual start: Execution (date) 20090808
    SEGNAM Segment Name E1EDL24
    POSNR Item number of the SD document 10
    MATNR Material Number 1112
    WERKS Plant SG01
    KDMAT Material belonging to the cust 1112
    LFIMG Actual quantity delivered (in 55
    VRKME Sales unit EA
    POSEX External item number 10
    ORMNG Original Quantity of Delivery 55
    SEGNAM Segment Name E1EDL41
    QUALI Qualifier for Reference Data o 001 : Purchase order data of customer
    BSTNR Customer purchase order number 4500004668
    BSTDT Customer purchase order date 10
    POSEX Item Number of the Underlying 10
    SEGNAM Segment Name E1EDL37
    Regards,
    Shamma

  • Updating Sales Order no in Production Order

    we have csenario for Sales Order :  Inquery - Quotation - Sales Order .
    In PP we have MTO scenarion . when i run MRP and convert the plan order to Production Order , in place of Sales Order it was updatin Quotation in Production Order .
    we have checked SD config for sales doc Item category =TAC and in Material Master we will used Item Category = NORM
    Please suggest is there any other setting for updating Sales Order no in Production Order .
    Thnx.

    Hi,
    I assume that you are using the strategy 20 (MTO). Go to OVZG here select the class 040 Indiv.cust.w/o cons., keep BLANK for account assignment consumption and rerun the whole cycle and check.
    Thanks
    Hrishi

  • Update sales order through workflow

    Hi,
       i developed one workflow for sales order.  after all aprovals the sales order is updating upto 2nd change. but 3rd change is not updating sales order.
    For updating sales order i am using BAPI_SALES ORDER_CHANGE function module.
    Thanks.

    Hi  Abdullah Azzouni         
    my scenario is when sales order is created or changed my workflow should trigger and make sales order as incomplete with  (Z field)  by using incompletion Procedure.
    Also some other custom fields there for other workflows in salesorder.
    In METHOD
       select single zfield1
                           zfield2
                           zfield3
                          Zfield4      <- for my workflow
                           INTO wa_ext_hdr
                          FROM vbak
                          WHERE vbeln = object-key-salesdocument.
           wa_ext_hdr-zfield ='X'.
       wa_ext_hdrx = 'XXXX'.
       MOVE 'U' TO wa_headerx-updateflag.
       MOVE: BAPE_VBAK  TO wa_extflds-structure.
       CONCATENATE object-key-salesdocument
                   wa_ext_hdr INTO
                   wa_extflds-valuepart1.
       APPEND wa_extflds TO i_extflds.
       MOVE: BAPE_VBAKX  TO wa_extflds-structure.
       CONCATENATE object-key-salesdocument
                   wa_ext_hdrx INTO
                   wa_extflds-valuepart1.
       APPEND wa_extflds TO i_extflds.
    CALL FUNCTION 'BAPI_SALESORDER_CHANGE'
    EXPORTING
       salesdocument     = object-key-salesdocument
       order_header_in   = wa_header
       order_header_inx  = wa_headerx
       behave_when_error = 'P'
    TABLES
       return            = i_return
         extensionin       = i_extflds.
    READ TABLE i_return INTO wa_return WITH KEY type = 'E'.
    iF sy-subrc EQ 0.
    ELSE.
    CALL FUNCTION 'BAPI_TRANSACTION_COMMIT'.
    ENDIF.
    Can you help on this.
    Please suggest me where i am wrong or if you know any other way to achieve this functionality guide me.
    Thanks in Advance.
    Raj

  • Update Service order status based on Sales order billing status

    Hi All,
    Pls give some suggestions for below scenario.
    Sales order will be created from Service order.
    Service order should get completed once the sales order is billed fully.
    Billing status is available in Sales order header. When ever billing is created, sales order status get updated.
    Where I need to have the trigger (User exit etc...) to update the service order status w.r.t sales order billing status.
    Rgds,
    Senni.B

    Hi,
    As standard the system update service status, maybe some config is missing. Please check the copy control conditions in SD.
    Hope this help.
    Regards.

Maybe you are looking for