BAPI or Function Module to create Handling Unit at the delivery level

Please send me the BAPI / FM details to create Handling Unit at the delivery level.
Thanks

Hi
you can try below BAPI's.
BAPI_HU_CREATE 
BAPI_HU_PACK
Hope this helps you.
Rgds,
Kris.

Similar Messages

  • Function Module for UNPACKING Handling Unit from Inbound Delivery

    Hello Experts,
    I am working on a RFID program to Receive goods from vendor...
    One of the steps of the program should CHANGE the quantity inside a received batch.
    To do so, I need to UNPACK the Handling Unit first... then change the quantity.
    I am using the following Function Modules to do so:
    - 'HU_GET_HUS'
    - 'V51P_FILL_GT'
    - 'HU_PACKING_AND_UNPACKING'
    - 'HU_POST'
    First 2 FM works fine...
    But when I get to the 3rd one, I keep getting "NOT_POSSIBLE" error...
    Have anyone done this before??
    Here's the code I've done to do some testing before putting it into my code...
    PLEEEEEEEEEEEASE HELP.
    TYPE-POOLS: vsep. PARAMETERS: p_venum LIKE vekp-venum.
    DATA: wa_object LIKE hum_object,
          it_object TYPE TABLE OF hum_object.
    DATA: wa_v51vp LIKE v51vp,
          it_v51vp TYPE TABLE OF v51vp.
    DATA: flag LIKE v51p_select_flags.
    DATA: it_venum            TYPE STANDARD TABLE OF hum_venum,
          ef_rcode            LIKE sy-subrc,
          et_vekp             TYPE STANDARD TABLE OF vsep_s_vekp,
          et_vepo             TYPE STANDARD TABLE OF vsep_s_vepo,
          et_vevw             TYPE vsep_t_vevw,
          et_highest_level    TYPE vsep_t_venum,
          et_messages         TYPE huitem_messages_t,
          is_packing_request  TYPE vsep_s_pithu,
          es_p_request        TYPE vsep_s_pithu,
          es_item             LIKE vepovb,
          cs_header           LIKE vekpvb,
          ef_number           TYPE vpobjkey,
          et_header           TYPE STANDARD TABLE OF vekpvb,
          et_items            TYPE STANDARD TABLE OF vepovb,
          et_item_serialno    TYPE vsep_t_rserob,
          et_history          TYPE hum_history_t,
          et_highest_levels   TYPE hum_venum_t.
    DATA: wa_venum            LIKE hum_venum,
          wa_vepo             TYPE vsep_s_vepo,
          wa_vekp             TYPE vsep_s_vekp,
          wa_items            TYPE vepovb,
          wa_header           TYPE vekpvb.
    START-OF-SELECTION.
      wa_venum-venum = p_venum.
      APPEND wa_venum TO it_venum.
      CALL FUNCTION 'HU_GET_HUS'
        EXPORTING
          it_venum          = it_venum
        IMPORTING
          et_header         = et_header
          et_items          = et_items
          et_item_serialno  = et_item_serialno
          et_history        = et_history
          et_highest_levels = et_highest_levels
          et_messages       = et_messages
        EXCEPTIONS
          hus_locked        = 1
          no_hu_found       = 2
          fatal_error       = 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.
      READ TABLE et_header INDEX 1 INTO wa_header.
      CALL FUNCTION 'V51P_FILL_GT'
        EXPORTING
          it_venum         = it_venum
        IMPORTING
          ef_rcode         = ef_rcode
          et_vekp          = et_vekp
          et_vepo          = et_vepo
          et_vevw          = et_vevw
          et_highest_level = et_highest_level
          et_messages      = et_messages
        EXCEPTIONS
          hu_locked        = 1
          no_hu_found      = 2
          fatal_error      = 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.
      READ TABLE et_vepo INDEX 1 INTO wa_vepo.
      READ TABLE et_vekp INDEX 1 INTO wa_vekp.
      MOVE-CORRESPONDING wa_vepo TO  is_packing_request.
      is_packing_request-belnr    = wa_vepo-vbeln.
      is_packing_request-quantity = wa_vepo-vemng.
      is_packing_request-veanz    = '-1'.
      is_packing_request-meins    = wa_vepo-vemeh.
      is_packing_request-exidv    = wa_vekp-exidv.
      CALL FUNCTION 'HU_PACKING_AND_UNPACKING'
        EXPORTING
          is_packing_request = is_packing_request
        IMPORTING
          ef_rcode           = ef_rcode
          es_p_request       = es_p_request
          es_item            = es_item
        CHANGING
          cs_header          = cs_header
        EXCEPTIONS
          missing_data       = 1
          hu_not_changeable  = 2
          not_possible       = 3
          customizing        = 4
          weight             = 5
          volume             = 6
          serial_nr          = 7
          fatal_error        = 8
          OTHERS             = 9.
      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 'HU_POST'
        EXPORTING
          if_synchron = 'X'
          if_commit   = 'X'
        IMPORTING
          ef_number   = ef_number.
      break nunfx004.
      IF sy-subrc <> 0.
    * MESSAGE ID SY-MSGID TYPE SY-MSGTY NUMBER SY-MSGNO
    *         WITH SY-MSGV1 SY-MSGV2 SY-MSGV3 SY-MSGV4.
      ENDIF.
    Thanks in advance,
    Fernanda

    Hi ,
    Check this code.
    Pack componet HU to Overpack HU. *
        l_packing_req-venum = g_ovrp_venum.                  "Overpack Internal HU
        l_packing_req-exidv = g_ovrp_exidv.                  "Overpack External HU
        l_packing_req-veanz = '1'.                     "PACK Constant
        l_packing_req-sub_hu_venum = l_int_venum.
        l_packing_req-sub_hu_exidv = l_int_exidv.       "Componet External HU
        l_packing_req-velin = '3'.                      "HU Type Constant
        l_packing_req-quantity = '1.000'.
    call function 'HU_PACKING_AND_UNPACKING'
          exporting
            is_packing_request = l_packing_req
          exceptions
            missing_data       = 1
            hu_not_changeable  = 2
            not_possible       = 3
            customizing        = 4
            weight             = 5
            volume             = 6
            serial_nr          = 7
            fatal_error        = 8
            others             = 9.
        if sy-subrc <> 0.
    error
          clear: v_msgv1, v_msgv2, v_msgv3.
          v_msgv1 = text-031.
       PERFORM display_message USING v_msgv1 v_msgv2 v_msgv3.
          leave to screen sy-dynnr.
        endif.
    No Errors --> POST HU
        call function 'HU_POST'
          exporting
            if_synchron = 'X'
            if_commit   = 'X'.
    plz write what you are passing to 'HU_PACKING_AND_UNPACKING' and hu_post fm.
    Regards
    Mohinder Singh Chauhan

  • Is there a BAPI or Function module can create a Customer Master record?

    Hi experts,
    In SE37, Is there a BAPI or Function module can create a Customer Master record?
    Regards

    BAPI_CUSTOMER_CREATEFROMDATA1
    also see this thread.
    Re: Create customer record  in SAP via BAPI
    кu03B1ятu03B9к

  • Bapi or function module to create a sales order in CRM 5.1 system

    Hi experts,
    Anyone knows any Bapi or function module to create a Sales order in CRM 5.1 system directly.
    Thanks.
    regards.
    Ruchi.

    hi ruchi,
    sory for the late respond, got a lot works to be done.
    based on my experience, you need several more information such as currency, uom for quantity, sales organization, etc.
    and honestly, i have never tried to create an order by just using 3 information ( sold to party, item, and quantity ),
    but i think it is possible because some of the information can be determined using configuration, but still some information is missing and the order that you create will have an error and you can't do next process of the order unless somebody fix / fill the information needed.
    just an idea, perhaps you need some z-tables to put your certain information needed for order creation and the information is maintained for each sold to party ( sold to party is a key of z-tables ) and each time order is created, all information will be query in this tables.
    and for this tables may be you can create an offline maintainance scenario using an adobe document. by this way, the sold to party can maintained all his/her/their information by them self.
    and by using this scenario, you can still maintain / create the order by programming ( perhaps using function module CRM_ORDER_MAINTAIN or else ).
    actually i want to implement in my company but don't have a chance becuase all has been set up and the management will think twice for implementing this scenario.
    hopes it hels
    cheers

  • BAPI or Function Module to create the Rebate Agreement

    Hi All,
    I have a requirement where I get the flat file which consists of the header and item level data. Using that I have to create the REBATE AGREEMENT. The transaction code to create the Rebate Agreement is VBO1 (Create Rebate Agreement).
    Is there any BAPI or FUNCTION MODULE available in SAP to create the Rebate Agreement. Please tell me if you know any suitable BAPI or FM.
    Thanks in advance.
    Best Regards,
    Paddu.

    Hi Paddu
    Were you able to find a BAPI or Function Module to create Rebate Agreement. We have a similar requirement where we have to create Rebate Agreements with Conditions.
    If you have found a solution do share it with us.
    Regards
    Salil

  • Are there BAPI or function modules for creating posting address ?

    Are there BAPI or function modules for creating posting address and budget address? We are currently use BDC program and T code FMBSPO_MULT (Posting address) and T code FMBSBO_MULT(budget address), but it is a very slow processing because we have thousands of funds centers.
    Your input will be appreciated!
    Regards,
    Fisher Li

    Li,
    You will have, may be more answers in the technical forum :
    https://www.sdn.sap.com/irj/sdn/collaboration
    Regards
    Valérie

  • I need a BAPI or function that can create a PO without the purchase req.

    I need a BAPI or function that can create a PO without the reference to a purchase requisition. We are creating "direct POs" (with no reference to PR) manually. And we have a large amount of documents to create. I can't figure out if BAPI_PO_CREATE and BAPI_PO_CREATE1 can help us by doing this, because I've understood this BAPIs creates POs only with the reference to a purchase requisition.
    Thanks in advance!!
    Sebastian

    Sorry I'm late guys, I couldn't replay your posts because I was busy.
    Charlie,
    ...just because we have the data already in the SAP system.
    My client doesn't want purchase requisitions to be created from the PM orders. Instead he asked us to create the purchase workflow by generating direct purchase orders from the PM orders, basically taking the information from the purchase agreement within the order's tasks. Maybe you don't understand a bit what I'm saying, but let me get this straight: we can't use LSMW because data doesn't come from a legacy.
    Ian,
    ...after all, and like you've said, we're gonna use BAPI_PO_CREATE1 for creating the POs. Today I finally realized that, purchase requisitions aren't mandatory for the bapi to perform the process. If something goes wrong, I'll let you know.
    Thanks anyway for your attention.
    Sebastian

  • BAPI or function module to create Budject (CJ30)

    Hi All,
       I need to create budget for a project (transaction CJ30) through BDC. As you know its critical to handle the screen
    in BDC can anyone suggest me any BAPI or function module which I use instead of BDC.
    Regards
    Jaker.

    Use function module KBPP_EXTERN_UPDATE_CO. Also take a look at [Note 625613 - Interface for overall planning and budgeting|https://service.sap.com/sap/support/notes/625613]
    Regards

  • Bapi or function module to create conter readings in service order

    hi all,
    i have used crm_service_order_create to create the service order it was very helpful . I could also create the service order with the i base component. But i need to enter the counter readings against the i base component. Is there any bapi ot function module which takes the counter id ex 1516 and saves the data in the service order. Reply at the earliest would be of great help.
    As the necessity is of high priority.
    Thanks in advance.
    Mithun Seshadri.

    Hi
    I need ur help.please send ur sample code for create a service order using Fm or BAPI
    Regards
    P.Prabhakaran

  • BAPI or Function Module to create MIC for TCode QS21

    Hi All,
    What is the BAPI or standard function Module that can be used to create Master Inspection Characteristics. The TCode to create MIC is QS21.
    Thanks in advance,
    Deep.

    Hi Prasad,
    I think we can't use BAPI_QPGR_SAVEREPLICA as it's for Catalog codes, not MIC.
    Moreover, we have BAPI_QPMK_SAVEREPLICA for MIC, but savereplica BAPIs can't be used to create records. This kind of BAPIs are used to save already created BAPIs.
    Thanks,
    Deep.

  • BAPI or function module for creating outbound delivery agains STO

    Hi,
    Is there any function module or BAPI to create an outboud delivery against STO?  Appreciated if anybody tells what are all the mandatory fields to pass.
    Thanks and Regards,
    Suresh

    Hi,
    Pls check the BAPIs,
    BAPI_OUTB_DELIVERY_CONFIRM_DEC BAPI for Outbound Delivery Confirmation from a Decentralized System
    BAPI_OUTB_DELIVERY_SPLIT_DEC   BAPI for Subsequent Outbound-Delivery Split from a Decentralized Syste
    Regards,
    Renjith Michael.

  • BAPI or Function Module for Creating a service order

    Dear developers,
    i want to create a service order in CRM from a web-based BSP application. Which function modules or bapi's can be used for this?
    Has anybody still did something like this?
    Regards,
    Jens

    Hi,
    U can use CRMXIF_ORDER_SAVE FM to create the service Order.
    Regards,
    Ajay Gupta
    Reward points only if it helps

  • Function module to create Invoice from the Delivery no ?

    Hi All,
    Is there any way (function module) to create an Invoice from the Delivery no and the Billing Type ? We do not want to go with BDC for transaction VF01.
    Details:
    We want to generate a pro-forma invoice while saving the delivery. We will have 'Special Function' (NAST-NACHA = 8) in the output determination and a routine would be called from there. That routine would contain the code to generate the Invoice. We will have only the 'Delivery no and the Billing Type'  in that routine. So trying to find any function module which can create an Invoice from the Delivery no and the Billing Type.
    Any suggestion / hint  is welcome.
    Thanks,
    Ashok

    Hello Ashok Satapathy ,
                                        The only option  for you is to call the FM "GN_INVOICE_CREATE" .
    There is no special FM availaible to pass only the delivery number at this point.
    You need to retrieve all the delivery information details and need to pass it to the FM "GN_INVOICE_CREATE".
    Thanks,
    Greetson

  • Bapi's or function modules to create, change( delete) partner functions

    Hi,
       Can anyone suggest BAPI or Function Modules for creating , changing the Partner Functions of the customer
    eg: To create customer XYZ as  bill-to-party of customer ZYX , i need  either a BAPI or Function Module.
    Thanks in Advance,
    Sabu

    Hi The following are the BAPI's to create and change the Partner Function.
    BAPI_BUS2001_PARTNER_CHANGE_M
    BAPI_BUS2001_PARTNER_CREATE_M
    Regards
    Vijay

  • Creating Handling Unit

    Hi All,
    Can anyone guide me which BAPI/FM to use to create Handling unit?
    And, How to update the delivery with the HU information?
    Was able to get the Handling Unit number through FM V51P_FIND_HEADER given the packaging Material number.
    Regards,
    Raj

    <b>Hi Rajasekhar,</b>
    I have mailed you the document on Handling Units.
    To create a Handling Unit you need to use the following BAPI Functional Module
    <b>BAPI_HU_CREATE</b>
    check the following Documentation:
    <b>FU BAPI_HU_CREATE</b>
    Text
    <b>Create Handling Unit with Items</b>
    <b>Functionality</b>
    You can use this method to create non-assigned handling units without stock information. These handling units may also be created with items, if you like. Serial numbers can also be included for each handling-unit item at this point.
    You can also create nested handling units by accessing this method more than once.
    Example
    <b>Example 1:</b>
    Creating a non-assigned handling unit with packaging material PALLET with a "Planned HU" physical status:
    HEADERPROPOSAL:        pack_mat  =  'PALETTE'
            hu_status_init =  'A'.
    <b>Example 2:</b>
    Following access of the above method (example 1), the return parameter HUKEY returns the ID of the handling unit that was created in the KEY = ID1 field. To pack the handling unit that was just created in another handling unit, call up the BAPI_HU_CREATE method again with the following import parameters:
    IHEADERPROPOSAL:        pack_mat = 'CONTAINER'
    ITEMPROPOS AL:              hu_item_type = '3'
    lower_level_key = ID1
    You have now created a nested handling unit (a pallet inside a container).
    <b>I suppose this will solve your problem.Also go through the document.</b>
    Thanks & Regards
    Pawan P.Khilari
    <b>*Mark Helpful Answers</b>
    Message was edited by: Pawan Khilari

Maybe you are looking for

  • Enter a business location for ECC 6 EHP 5 (Taiwan)

    Hi, While releasing the billing doc to accounting we are getting the error Enter a business location Message no. F5A192 We are working on ECC6 EHP 5 and this requirement is for Taiwan. I have found the SAP Note; 376018, however this is valid for 4.6c

  • Moving to UK for a year from US - What are my options?

    Okay, so my wife and I are moving to Edinburgh in two weeks, for a 1yr stay. I currently have an iPhone 4 and she has the iPhone 3Gs. I just got off the phone with AT&T and my options are to put our account on a 'reduced rate suspension' which means

  • Messaging not functioning correctly

    My husband and I have Iphones 3.  I can no longer receive messages from his phone and there is a little pale blue "thought bubble" icon beside my name in the message area of his phone.  What is that?

  • Photosmart 8050 won't communicate with my computer

    My Photosmart 8050 printer has stopped communicating with my Dell computer. I have run the HP Print Diagnositc Utility scan and just get an alert that there is a connectivity issue. I have tried three different USB cables and determined that the cabl

  • Safari Does Not Clear History

    If I Reset Safari or Empty Cache or Clear History when I go to the address bar and type any letter--I get a long list of all the websites visited. While this is not a big deal for my home computer I do not like this to occur on my work computer. Is t