Creation of BDC for a part of process.

Hi,
We are creating a BDC for PA40 action. It has a series of Info Types which come one by one. Now our requirement is to skip the last Info Type and create a recording for the process. is this possible.
We require this as the last Info type is Pensions Fund GB, this takes us through all the old records before we can make a new entry and the number of old records for different employees is different, hence no standard recording is possible. Can anyone suggesta way forward.
Thank you,
Arpita Arora

Hi,
In BDC program, when you are running the loop for each employee,You initially check the number of record for that employee in It0071 in that loop itself.
in your code then write,
Do N times.
BDC recording to exit screen with OK_CODE = '/ENXT'
enddo.
This will be in the loop of each employee record.
Thanks,
Sutapa.

Similar Messages

  • Problem in creation of BDC for transaction phap_create

    Hello Friends,
    I am trying to create BDC for PHAP_CREATE.
    When you run a transaction a pop up window appears to select the template id.
    And in BDC it is selected by cursor position. So once selected, the value of template id cannot be changed.
    I want this as a parameter.So that each time I run a BDC I will be able to create different types of Appraisal documents i.e with different template ids.
    How to go about it???
    Regards,
    Bhushan

    Hi,
    For selecting the id, while doing recording,
    record with
    CTRL + F ( Where u can give ur id) and proceed further.

  • Problem while SO creation through BDC

    Hi Experts,
    The follow problem  came in log file of SM35 ,while SO creation through BDC for some sales org.
      Runtime error COMPUTE_BCD_OVERFLOW has occurred.
    could you please tell me what is problem.
    Thanks
    jai

    Hi
    It could be the following reasons,
    1. Too many orders
    2. Mismatch in the field, like fields skip a line so data not matching.
    Check these
    <b>Reward if it helped!</b>
    Chandru

  • Upload data for Tcode LT06(Transfer order creation) using BDC -very urgent

    hi experts,
          I got stucked up in writing a BDC for the Tcode LT06(Transfer order creation using wearhouse number) in MM module,
    the problem is like this, when i go to the tcode LT06 , it will ask for material doucument,mat. docu. year and wearhouse number, iam entering the inputs and then press enter, as soon as i press enter it takes me to the second screen where i will be selecting the item and then click on the button called  'Generate TO item'
    here the problem arises, as soon as i click the button iam getting a standard SAP error message(No Destination Storage Bin found in storage type 'IMP'). Due to this errror iam not able populate the batch input data on the screen, suggest me a proper solution. rewards will given if solution found useful.
    Kishore K

    Hi ,
    I have done the same in Background with BDC and TR Number for Multiple Materials ,
    Can u please explain the scenario, so then I would be able to try for solution ?
    Warm Regards.

  • Hi gurur's in BDC for recording other than SHDB any process is there

    hi gurur's in BDC for recording other than SHDB any process is there

    Hi,
    I think as such there is no other process. You can do the recording through transaction SM35 as well, go there and click on new recording. You can do the recording this way also but this is not different from SHDB.
    Reward if this clarifies your doubt.
    Regards,
    Lalit Kabra

  • BDC for MM01(Material creation)

    Hello Please anybody send me code for creating materials with reference to reference material and plant in sselection screen in version ECC 6.0?
    My selection screen will be::
    Reference material:                                                       Plant:

    Plz User <b>BAPI_MATERIAL_SAVEDATA</b>
    Why So :
    you will never get it to work correctly in all cases every time for all material types, it is just much easier to work with an API that is not screen dependent. Then you don't have to worry about all of the exceptions when dealing with certain material types, and such. For example, say you have a material which you want to update the po text, and you did your recording for another material, which didn't have a specific view, so now when doing BDC for this material, the screen where you select the view you want to process, may be in a different place in the table control, see what I'm getting at? Its just very much easier to work with BAPIs and is suggest to use BAPI over BDC whenever possible.
    Also still u want to go for it, check this code :
    REPORT Y730_BDC5 .
    *HANDLING TABLE CONTROL IN BDC
    DATA : BEGIN OF IT_DUMMY OCCURS 0,
    DUMMY(100) TYPE C,
    END OF IT_DUMMY.
    DATA : BEGIN OF IT_XK01 OCCURS 0,
    LIFNR(10) TYPE C,
    BUKRS(4) TYPE C,
    EKORG(4) TYPE C,
    KTOKK(4) TYPE C,
    NAME1(30) TYPE C,
    SORTL(10) TYPE C,
    LAND1(3) TYPE C,
    SPRAS(2) TYPE C,
    AKONT(6) TYPE C,
    FDGRV(2) TYPE C,
    WAERS(3) TYPE C,
    END OF IT_XK01,
    BEGIN OF IT_BANK OCCURS 0,
    BANKS(3) TYPE C,
    BANKL(10) TYPE C,
    BANKN(10) TYPE C,
    KOINH(30) TYPE C,
    LIFNR(10) TYPE C,
    END OF IT_BANK.
    DATA : IT_BDCDATA LIKE BDCDATA OCCURS 0 WITH HEADER LINE,
    IT_BDCMSGCOLL LIKE BDCMSGCOLL OCCURS 0 WITH HEADER LINE.
    CALL FUNCTION 'WS_UPLOAD'
    EXPORTING
    FILENAME = 'C:\VENDOR.TXT'
    FILETYPE = 'ASC'
    TABLES
    DATA_TAB = IT_DUMMY.
    LOOP AT IT_DUMMY.
    IF IT_DUMMY-DUMMY+0(2) = '11'.
    IT_XK01-LIFNR = IT_DUMMY-DUMMY+2(10).
    IT_XK01-BUKRS = IT_DUMMY-DUMMY+12(4).
    IT_XK01-EKORG = IT_DUMMY-DUMMY+16(4).
    IT_XK01-KTOKK = IT_DUMMY-DUMMY+20(4).
    IT_XK01-NAME1 = IT_DUMMY-DUMMY+24(30).
    IT_XK01-SORTL = IT_DUMMY-DUMMY+54(10).
    IT_XK01-LAND1 = IT_DUMMY-DUMMY+64(3).
    IT_XK01-SPRAS = IT_DUMMY-DUMMY+67(2).
    IT_XK01-AKONT = IT_DUMMY-DUMMY+69(6).
    IT_XK01-FDGRV = IT_DUMMY-DUMMY+75(2).
    IT_XK01-WAERS = IT_DUMMY-DUMMY+77(3).
    APPEND IT_XK01.
    ELSE.
    IT_BANK-BANKS = IT_DUMMY-DUMMY+2(3).
    IT_BANK-BANKL = IT_DUMMY-DUMMY+5(10).
    IT_BANK-BANKN = IT_DUMMY-DUMMY+15(10).
    IT_BANK-KOINH = IT_DUMMY-DUMMY+25(30).
    IT_BANK-LIFNR = IT_DUMMY-DUMMY+55(10).
    APPEND IT_BANK.
    ENDIF.
    ENDLOOP.
    LOOP AT IT_XK01.
    REFRESH IT_BDCDATA.
    perform bdc_dynpro using 'SAPMF02K' '0100'.
    perform bdc_field using 'BDC_CURSOR'
    'RF02K-REF_LIFNR'.
    perform bdc_field using 'BDC_OKCODE'
    '/00'.
    perform bdc_field using 'RF02K-LIFNR'
    IT_XK01-LIFNR.
    perform bdc_field using 'RF02K-BUKRS'
    IT_XK01-BUKRS.
    perform bdc_field using 'RF02K-EKORG'
    IT_XK01-EKORG.
    perform bdc_field using 'RF02K-KTOKK'
    IT_XK01-KTOKK.
    perform bdc_dynpro using 'SAPMF02K' '0110'.
    perform bdc_field using 'BDC_CURSOR'
    'LFA1-TELX1'.
    perform bdc_field using 'BDC_OKCODE'
    '/00'.
    perform bdc_field using 'LFA1-NAME1'
    IT_XK01-NAME1.
    perform bdc_field using 'LFA1-SORTL'
    IT_XK01-SORTL.
    perform bdc_field using 'LFA1-LAND1'
    IT_XK01-LAND1.
    perform bdc_field using 'LFA1-SPRAS'
    IT_XK01-SPRAS.
    perform bdc_dynpro using 'SAPMF02K' '0120'.
    perform bdc_field using 'BDC_CURSOR'
    'LFA1-KUNNR'.
    perform bdc_field using 'BDC_OKCODE'
    '/00'.
    perform bdc_dynpro using 'SAPMF02K' '0130'.
    perform bdc_field using 'BDC_CURSOR'
    'LFBK-KOINH(02)'.
    perform bdc_field using 'BDC_OKCODE'
    '=ENTR'.
    DATA : FNAM(20) TYPE C,
    IDX TYPE C.
    MOVE 1 TO IDX.
    LOOP AT IT_BANK WHERE LIFNR = IT_XK01-LIFNR.
    CONCATENATE 'LFBK-BANKS(' IDX ')' INTO FNAM.
    perform bdc_field using FNAM
    IT_BANK-BANKS.
    CONCATENATE 'LFBK-BANKL(' IDX ')' INTO FNAM.
    perform bdc_field using FNAM
    IT_BANK-BANKL.
    CONCATENATE 'LFBK-BANKN(' IDX ')' INTO FNAM.
    perform bdc_field using FNAM
    IT_BANK-BANKN.
    CONCATENATE 'LFBK-KOINH(' IDX ')' INTO FNAM.
    perform bdc_field using FNAM
    IT_BANK-KOINH.
    IDX = IDX + 1.
    ENDLOOP.
    perform bdc_dynpro using 'SAPMF02K' '0130'.
    perform bdc_field using 'BDC_CURSOR'
    'LFBK-BANKS(01)'.
    perform bdc_field using 'BDC_OKCODE'
    '=ENTR'.
    perform bdc_dynpro using 'SAPMF02K' '0210'.
    perform bdc_field using 'BDC_CURSOR'
    'LFB1-FDGRV'.
    perform bdc_field using 'BDC_OKCODE'
    '/00'.
    perform bdc_field using 'LFB1-AKONT'
    IT_XK01-AKONT.
    perform bdc_field using 'LFB1-FDGRV'
    IT_XK01-FDGRV.
    perform bdc_dynpro using 'SAPMF02K' '0215'.
    perform bdc_field using 'BDC_CURSOR'
    'LFB1-ZTERM'.
    perform bdc_field using 'BDC_OKCODE'
    '/00'.
    perform bdc_dynpro using 'SAPMF02K' '0220'.
    perform bdc_field using 'BDC_CURSOR'
    'LFB5-MAHNA'.
    perform bdc_field using 'BDC_OKCODE'
    '/00'.
    perform bdc_dynpro using 'SAPMF02K' '0310'.
    perform bdc_field using 'BDC_CURSOR'
    'LFM1-WAERS'.
    perform bdc_field using 'BDC_OKCODE'
    '/00'.
    perform bdc_field using 'LFM1-WAERS'
    IT_XK01-WAERS.
    perform bdc_dynpro using 'SAPMF02K' '0320'.
    perform bdc_field using 'BDC_CURSOR'
    'WYT3-PARVW(01)'.
    perform bdc_field using 'BDC_OKCODE'
    '=ENTR'.
    perform bdc_dynpro using 'SAPLSPO1' '0300'.
    perform bdc_field using 'BDC_OKCODE'
    '=YES'.
    CALL TRANSACTION 'XK01' USING IT_BDCDATA
    MODE 'A'
    UPDATE 'S'
    MESSAGES INTO IT_BDCMSGCOLL.
    ENDLOOP.
    FORM BDC_DYNPRO USING PROG SCR.
    CLEAR IT_BDCDATA.
    IT_BDCDATA-PROGRAM = PROG.
    IT_BDCDATA-DYNPRO = SCR.
    IT_BDCDATA-DYNBEGIN = 'X'.
    APPEND IT_BDCDATA.
    ENDFORM.
    FORM BDC_FIELD USING FNAM FVAL.
    CLEAR IT_BDCDATA.
    IT_BDCDATA-FNAM = FNAM.
    IT_BDCDATA-FVAL = FVAL.
    APPEND IT_BDCDATA.
    ENDFORM.
    All things r available in SDN, please search.
    Reward points if useful.
    Thanks
    vinsee

  • Process for Replacement for rejected parts by vendor

    Dear All,
    We are facing a problem in mapping the process of Replacement for rejected parts by vendor.
    Scenario:
    In case of import vendors, material is received in stock and payment is made to vendor thru Invoice.
    Now in case of defected parts vendor sends the replacement and the defected part is scrapped.
    Is there a process to receive the replacement part with proper accountability ?
    Thanks & Regards,
    Ritesh.

    Hi AP,
    We are scrapping the rejected material. Can you explain which movement type is used to put rejected stock to vendor movement type.
    Thanks & Regds,
    Ritesh.

  • Bdc for tocde CS01(BOM CREATION)

    Hi,
    I want to make a bdc for the tcode CS01(BOM Creation),but the thing when i perform the Recording then there is a point that the BOM having the sub - items which might be 3 or 2 or maybe 10 . how can i manage that during the recording.
    plzz provide me guidelines for solving this problem.

    Hi,
    This code for BOM creation/Change,
    using BAPI as well as BDC check this.
                    LOOP AT it_bom_create INTO wa_bom_create.
    * Begin of CCT51465 - B09794 - 11/28/2007
    *                  PERFORM f_bdc_dynpro      USING 'SAPLCSDI' '0100'.
    *                  PERFORM f_bdc_field       USING 'BDC_OKCODE'
    *                                                  '/00'.
    *                  PERFORM f_bdc_field       USING 'RC29N-MATNR'
    *                                                  wa_bom_create-matnr.
    *                  PERFORM f_bdc_field       USING 'RC29N-WERKS'
    *                                                  wa_mbew-bwkey.
    *                  PERFORM f_bdc_field       USING 'RC29N-STLAN'
    *                                                  '2'.
    *                  PERFORM f_bdc_field       USING 'RC29N-STLAL'
    *                                                  '01'.
    *                  PERFORM f_bdc_dynpro      USING 'SAPLCSDI' '0110'.
    *                  PERFORM f_bdc_field       USING 'BDC_OKCODE'
    *                                                  '/00'.
    *                  CONDENSE wa_bom_create-bmeng.
    *                  PERFORM f_bdc_field       USING 'RC29K-BMENG'
    *                                                  wa_bom_create-bmeng.
    *                  PERFORM f_bdc_dynpro      USING 'SAPLCSDI' '0111'.
    *                  PERFORM f_bdc_field       USING 'BDC_OKCODE'
    *                                                  '/00'.
    *                  CONDENSE wa_bom_create-menge.
    *                  PERFORM f_bdc_dynpro      USING 'SAPLCSDI' '0140'.
    *                  PERFORM f_bdc_field       USING 'BDC_CURSOR'
    *                                                  'RC29P-IDNRK(01)'.
    *                  PERFORM f_bdc_field       USING 'BDC_OKCODE'
    *                                                  '/00'.
    *                  PERFORM f_bdc_field       USING 'RC29P-IDNRK(01)'
    *                                                  wa_bom_create-idnrk.
    *                  CONDENSE wa_bom_create-menge.
    *                  PERFORM f_bdc_field       USING 'RC29P-MENGE(01)'
    *                                                  wa_bom_create-menge.
    *                  PERFORM f_bdc_field       USING 'RC29P-POSTP(01)'
    *                                                  'L'.
    *                  PERFORM f_bdc_dynpro      USING 'SAPLCSDI' '0130'.
    *                  PERFORM f_bdc_field       USING 'BDC_OKCODE'
    *                                                  '/00'.
    *                  PERFORM f_bdc_dynpro      USING 'SAPLCSDI' '0131'.
    *                  PERFORM f_bdc_field       USING 'BDC_OKCODE'
    *                                                  '/00'.
    *                  PERFORM f_bdc_dynpro      USING 'SAPLCSDI' '0140'.
    *                  PERFORM f_bdc_field       USING 'BDC_OKCODE'
    *                                                  '=FCBU'.
    *                  PERFORM f_bdc_transaction USING 'CS01'.
                      it_stko1-base_quan = wa_bom_create-bmeng.
                      CALL FUNCTION 'CSAP_MAT_BOM_CREATE'
                        EXPORTING
                          material                 = wa_bom_create-matnr
                          plant                    = wa_marc-werks
                          bom_usage                = '2'
                          valid_from               = v_valid              " CCT52206 - B09794 - 12/10/2007
    *                     CHANGE_NO                =
    *                     REVISION_LEVEL           =
                          i_stko                   = it_stko1
    *                     FL_NO_CHANGE_DOC         = ' '
                          fl_commit_and_wait       = 'X'
    *                     FL_CAD                   = ' '
                          fl_default_values        = ' '
                        IMPORTING
                          fl_warning               = flg_warning
    *                     BOM_NO                   =
                        TABLES
                          t_stpo                   = it_stpo1
    *                     T_DEP_DATA               =
    *                     T_DEP_DESCR              =
    *                     T_DEP_ORDER              =
    *                     T_DEP_SOURCE             =
    *                     T_DEP_DOC                =
    *                     T_LTX_LINE               =
    *                     T_STPU                   =
                        EXCEPTIONS
                          error                    = 1
                          OTHERS                   = 2.
                      IF sy-subrc <> 0.
    * Begin of CCT59311 - B09794 - 07/01/2008
                        IF p_show = 'X'.
                          PERFORM f_check_lock.
                        ENDIF.
    * End of CCT59311 - B09794 - 07/01/2008
                        CALL FUNCTION 'FORMAT_MESSAGE'
                          EXPORTING
                            id        = sy-msgid
                            lang      = sy-langu
                            no        = sy-msgno
                            v1        = sy-msgv1
                            v2        = sy-msgv2
                            v3        = sy-msgv3
                            v4        = sy-msgv4
                          IMPORTING
                            msg       = v_mstring
                          EXCEPTIONS
                            not_found = 1
                            OTHERS    = 2.
                        IF sy-subrc = 0.
                          CONDENSE v_mstring.
                          wa_errormsg-matnr = wa_bom_create-matnr.
                          wa_errormsg-werks = wa_marc-werks.
                          wa_errormsg-mtart = v_mat_typ.
                          wa_errormsg-msgtyp = sy-msgty.
                          IF sy-msgid = '29' AND sy-msgno = '037'.
                            v_mstring = text-027.                                   "  Costing BOM already exist (For Material -
                            CONCATENATE v_mstring wa_marc-matnr ')' INTO v_mstring.
                            wa_errormsg-msgtxt = v_mstring.
                          ELSE.
                            wa_errormsg-msgtxt = v_mstring.
                          ENDIF.
                          APPEND wa_errormsg TO it_errormsg1.
                          CLEAR wa_errormsg.
                        ENDIF.
                      ELSE.
                        wa_successmsg-matnr = wa_marc-matnr.
                        wa_successmsg-werks = wa_marc-werks.
                        wa_successmsg-mtart = v_mat_typ.
                        wa_successmsg-msgtyp = 'S'.
                        v_mstring = text-017.       "   Costing BOM created successfully (For Material -
                        CONCATENATE v_mstring wa_marc-matnr ')' INTO v_mstring.
                        wa_successmsg-msgtxt = v_mstring.
                        APPEND wa_successmsg TO it_successmsg.
                        CLEAR wa_successmsg.
                      ENDIF.
    Code Formatted by: Alvaro Tejada Galindo on Dec 23, 2008 10:21 AM

  • LSMW/BDC for service PO creation

    Dear all,
    Can anybody pl suggest how to create an LSMW or BDC for service PO creation with multiple
    line items and under each line item there will be multiple service line items also.
    Thx
    Amitava

    hi,
    You could do LSMW without the help of a technical consultant.
    In LSMW you could create a PO by BDc or through BAPI.
    Make use of the BAPI to create.
    BAPI_PO_CREATE1. ( Nothing but a Se37 Function module).
    the parmeters required can be checked in funcition module documentaion in the bapi.
    Hope this helps.
    harish

  • BDC for MIGO for GR OutBound Delivery( A01 & R05 ) from Movement Type 107 to 109

    Hi,
    I am stuck with a very typical situation need all your expertise and advices for a solution.
    We are basically trying to create change the movement type from 107 to 109 through MIGO.
    I have made a BDC recording for MIGO ( because we would like to track each delivery specifically under shipment , I know that there is a BAPI which is there to do this but it works fine if we do the shipment with Purchase Order as input which dont want in that manner )
    Process:
    1. Creating Production Order
    2. Creating Purchase Order
    3. Creating STO
    4. Deliveries
    5. PGI for Deliveries
    6. Shipment for group of outbound Deliveries
    I have created a z program where i am passing shipment number in the selection screen.
    Then it would take all the deliveries for that shipment and pass each delivery to MIGO and process it and change the status from 107 to 109.
    Interesting part here is, the code works absolutely perfect only from my ID. But when I test from other ID it is not executing, so to check where is the problem I have added mess_tab to the CALL TRANSACTION to capture what message is been populated for my ID comparing with others
    Message Captured on Others ID's:
    MSGID: 00
    MSGNR: 344
    MSGV1: SAPLMIGO
    MSGV2: 1300
    Message Captured on MY ID:
    MSGID: MIGO
    MSGNR: 012
    MSGV1: 5000005802
    MSGV2: (empty)
    This is the problem this program is executing only on MY ID, rest all ID's it is not processing.
    We have cross verified with security and basis regarding any authorization issues but nothing came up.
    Please help me what could be the issue ( WHY it is processing successfully for my and WHY NOT for other ID's)
    Below is the main code :
    CALL FUNCTION 'CONVERT_DATE_TO_EXTERNAL'                     " Converting Date format to DD/MM/YYYY
         EXPORTING
           DATE_INTERNAL            = sy-datum
         IMPORTING
           DATE_EXTERNAL            = lv_date_external
         EXCEPTIONS
           DATE_INTERNAL_IS_INVALID = 1
           OTHERS                   = 2.
           IF SY-SUBRC <> 0.                                     "#EC NEEDED
    * Implement suitable error handling here
           ENDIF.
    *   Validating input shipment number with database table VTTP
           SELECT VTTP~TKNUM
                  VTTP~TPNUM
                  VTTP~VBELN
             FROM VTTP INNER JOIN VTTK
             ON VTTP~TKNUM = VTTK~TKNUM
             INTO TABLE IT_VTTP
             WHERE VTTK~TKNUM = P_TKNUM
               AND VTTK~STDIS = 'X'.
           IF sy-subrc = 0.
    *   Validating all deliveries having same Delivery type or not
             SELECT * FROM likp INTO TABLE it_likp FOR ALL ENTRIES IN it_vttp WHERE vbeln = it_vttp-vbeln
                                                                                AND vbtyp = 'J'.
             IF sy-subrc = 0.
               CLEAR lv_lines.
               LOOP AT it_likp INTO wa_likp.
                 REFRESH:it_vbfa,BDCDATA.
    *   Validating if Delivery Type = 109 (GR already done), or Delivery Type = 107 (must process for GR )
                 SELECT * FROM vbfa INTO TABLE it_vbfa WHERE vbelv = wa_likp-vbeln
    *                                                AND vbtyp_v = 'J'
                                                         AND bwart = '109'.
                 IF sy-subrc = 0.
                   lv_flag1 = 'X'.
                 ELSE.
                   SELECT * FROM vbfa INTO TABLE it_vbfa WHERE vbelv = wa_likp-vbeln
    *                                                  AND vbtyp_v = 'J'
                                                           AND bwart = '107'.
                   IF sy-subrc NE 0.
                     MESSAGE 'No Deliveries with Movement Type "107" ' TYPE 'I'.
                   ELSE.
                     lv_flag2 = 'X'.
                     lv_lines = lv_lines + 1.
    **  BDC for MIGO
                     perform bdc_dynpro      using 'SAPLMIGO' '0001'.
                     perform bdc_field       using 'BDC_OKCODE'
                                                   '=OK_GO'.
                     perform bdc_field       using 'GODYNPRO-ACTION'
                                                   'A01'.
                     perform bdc_field       using 'GODYNPRO-REFDOC'
                                                   'R05'.
                     perform bdc_field       using 'GODEFAULT_TV-BWART'
                                                   '109'.
                     perform bdc_field       using 'BDC_CURSOR'
                                                   'GODYNPRO-OUTBOUND_DELIVERY'.
                     perform bdc_field       using 'GODYNPRO-OUTBOUND_DELIVERY'
                                                   wa_likp-vbeln. "'80019574'.
                     perform bdc_field       using 'GOHEAD-BLDAT'
                                                   lv_date_external. "'04/29/2015'.
                     perform bdc_field       using 'GOHEAD-BUDAT'
                                                   lv_date_external. "'04/29/2015'.
                     perform bdc_field       using 'GOHEAD-WEVER'
                                                   '1'.
                     perform bdc_dynpro      using 'SAPLMIGO' '0001'.
                     perform bdc_field       using 'BDC_OKCODE'
                                                   '=OK_POST1'.
                     perform bdc_field       using 'GODEFAULT_TV-BWART'
                                                   '109'.
                     perform bdc_field       using 'GOHEAD-BLDAT'
                                                   lv_date_external. "'04/29/2015'.
                     perform bdc_field       using 'GOHEAD-LFSNR'
                                                   wa_likp-vbeln. "'0080019574'.
                     perform bdc_field       using 'GOHEAD-BUDAT'
                                                   lv_date_external. "'04/29/2015'.
                     perform bdc_field       using 'GOHEAD-WEVER'
                                                   '1'.
                     perform bdc_field       using 'GODYNPRO-DETAIL_ZEILE'
                                                   '   1'.
                     perform bdc_field       using 'GOITEM-ERFME'
                                                   'EA'.
                     perform bdc_field       using 'GOITEM-ERFMG'
                                                   '1'.
                     perform bdc_field       using 'GOITEM-LSMNG'
                                                   '1'.
                     perform bdc_field       using 'GOITEM-LSMEH'
                                                   'EA'.
                     perform bdc_field       using 'GOITEM-MIGO_ELIKZ'
                                                   '1'.
                     perform bdc_field       using 'GOITEM-BWART'
                                                   '109'.
                     perform bdc_field       using 'GOITEM-LGOBE'
                                                   'RX Cross-docking'.
                     perform bdc_field       using 'BDC_CURSOR'
                                                   'GODYNPRO-DETAIL_TAKE'.
                     perform bdc_field       using 'GODYNPRO-DETAIL_TAKE'
                                                   'X'.
                     PERFORM bdc_dynpro      USING 'SAPLMIGO' '1300'.
                     PERFORM bdc_field       USING 'BDC_CURSOR'
                                                   'G_TIP_DONT_SHOW_AGAIN'.
                     PERFORM bdc_field       USING 'BDC_OKCODE'
                                                   '=OK_TIP_GO'.
                     PERFORM bdc_field       USING 'G_TIP_DONT_SHOW_AGAIN'
                                                   'X'.
    *& Avoid unncessary screens to populate while processing background.
                     LV_OPTIONS-DISMODE = 'N'.
                     LV_OPTIONS-UPDMODE = 'S'.
                     LV_OPTIONS-NOBINPT = 'X'.
                     CALL TRANSACTION 'MIGO' USING BDCDATA  OPTIONS FROM LV_OPTIONS MESSAGES INTO IT_MESSTAB1 .
                     WAIT UP TO 1 SECONDS.
                     DELETE IT_MESSTAB1 WHERE MSGTYP NE 'E'.
                     IF IT_MESSTAB1[] IS NOT INITIAL.
                       APPEND LINES OF IT_MESSTAB1 TO IT_MESSTAB.
                     ENDIF.
                   ENDIF.
                 ENDIF.
               ENDLOOP.
             ENDIF.
           ELSE.
             MESSAGE 'Shipment Number does not exists Or not Planned' TYPE 'E'.
           ENDIF.
         ELSE.
           MESSAGE 'Please insert Shipment Number' TYPE 'E'.
         ENDIF.
         IF lv_flag1 = 'X' AND lv_flag2 = 'X'.
           MESSAGE 'This shipment is processed with an inconsistent goods receipt' TYPE 'I'.
         ELSEIF lv_flag1 = 'X'.
           MESSAGE 'Shipment already been processed for these deliveries' TYPE 'I'.
         ELSEIF lv_flag2 = 'X'.
           lv_lines1 = lv_lines.
           CONDENSE lv_lines1 NO-GAPS .
           CONCATENATE lv_lines1 'Goods Receipt are posted for the shipment '
                  INTO lv_message SEPARATED BY space.
           MESSAGE  lv_message TYPE 'I'.
         ENDIF.
    * Display Messages from Message TAB.
         DELETE ADJACENT DUPLICATES FROM IT_MESSTAB.
         DATA:lv_msg TYPE string.
         LOOP AT IT_MESSTAB INTO WA_MESSTAB.
           CALL FUNCTION 'FORMAT_MESSAGE'
             EXPORTING
               ID        = WA_MESSTAB-MSGID
               NO        = WA_MESSTAB-MSGNR
               V1        = WA_MESSTAB-MSGV1
               V2        = WA_MESSTAB-MSGV2
               V3        = WA_MESSTAB-MSGV3
               V4        = WA_MESSTAB-MSGV4
             IMPORTING
               MSG       = lv_msg
             EXCEPTIONS
               NOT_FOUND = 1
               OTHERS    = 2.
           IF sy-subrc <> 0.
    * Implement suitable error handling here
           ENDIF.
           WRITE:/ lv_msg.
         ENDLOOP.
    *        Start new screen                                              *
       FORM BDC_DYNPRO USING PROGRAM DYNPRO.                 "#EC PF_NO_TYPE
         CLEAR BDCDATA.
         BDCDATA-PROGRAM  = PROGRAM.
         BDCDATA-DYNPRO   = DYNPRO.
         BDCDATA-DYNBEGIN = 'X'.
         APPEND BDCDATA.
       ENDFORM.
    *        Insert field                                                  *
       FORM BDC_FIELD USING FNAM FVAL.                       "#EC PF_NO_TYPE
         CLEAR BDCDATA.
         BDCDATA-FNAM = FNAM.
         BDCDATA-FVAL = FVAL.
         APPEND BDCDATA.
       ENDFORM.
    Thanks,
    Srini

    Hi Rob,
    Thanks for quick reply.
    I have checked the NOTE : 304122
    But there in the NOTE it says ( " BAPI, BAPI_GOODSMVT_CANCEL, BAPI_GOODSMVT_CREATE, CNTL_ERROR" )
    These BAPI's work perfectly for (purchase order as input type), but here out type is ( A01 & R05 ) we are giving DELIVERY NUMBER as input to MIGO.
    So for this scenario we cannot use those BAPI's mentioned in the NOTE.
    Also as stated earlier in the message interesting part is
    "The code works absolutely perfect only from my ID. But when I test from other ID it is not executing. Code is working exactly as expected ONLY to my ID. When i try to execute the same code from another's ID it is not working"
    So what do you think might be the issue?

  • Material Creation Using BDCs.

    Hi all,
    I have developed a program for Material Creation using BDC.
    Material is Being created and that is working well and good.Here i have a Requirement to update the Newly creted material in Ztable.So when i use call transaction mathod,i have written code for updation under the line CALL TRANSACTION.where in iam getting newly creatde material from MARA table,and so it is working perfectly fine..
    But our requirement should be sessions method,so when i use sessions method and exeute the program..we face the problem of updation.
    the piece of code for updation is updating previously created material.
    Literally speaking only the sessions are created ,when the program is executed,material is not created when program is run.Material is only created when the sessions are processed using SM35,
    So how should i do here,where should be the updation code written and where will we get the newly created material in sessions method..
    Pls Help me in solving this problem

    hai priyanaka it might be due to configuration problem
    bcos manulay also ur gettign this , so just consult ur MM consultant for soem setting
    regards
    afzal

  • BDC  For Bank Reconsilation.

    Dear friends,
            I want to create BDC for bank reconcillation using Tcodes FF67 and FEBA.
    So I want to know whether we can create BDC for such a transactional data or there may be any other solution for the same. Beacuse it is very complicated process.
    Regards,
    Madan.

    hi kapilan,
    i do have problems while creating BDC for FI12 T.Code.
    After brief analysis i found that:
    1. its not standard transaction code but its part of customizing setting.
    2. at end it creates transport request.
    after consulting our function consultant. the decision was to create different recordings for House Bank Adress data and bank accounts.
    try this way.
    Regards,
    krishna chaitanya

  • BDC for C201(Master Recipe Create)

    Dear,
    Please help me in the following situation:
    I have written a BDC for transaction code C201 for Master Recipe Creation. Its running ok.
    But I have doubts like
    for the 1st table control:
    1) if for one operartion there are more than 1 phases
        then what precautions are needed for page down.
    for the 2nd level inner table control:
    1) I am in the process of coding pagedown for this 2nd table control. If I have to code for it what all precautions will I have to take?
    And in total what all precautions will I have to take?
    How feasible is this BDC?
    I have searched for BAPI, but did not find one.
    Kindly help me. I am under client pressure.
    Thanks.
    Regards,
    Shambhavi.
    Edited by: Shambhavi Salunkhe on Jun 23, 2008 9:40 PM

    Hi,
    In C201 transaction we have a table control in the operations screen. below the table control we have some push buttons and a input text field, we can make use this field to handle the table control. If you are insertinga first operation, enter the value in first row of the table control. for the second operation onwards enter max valye like 99999 in the input text box and click on enter. all the previous rows will scroll up and always second row of the table control will be free, so you can put the data in the second row. in the same way you will have some button to handle the other table control too .I hope this will help You
    Thanks,
    rajinikanth
    Edited by: Rajinikanth G on Jun 23, 2008 6:53 PM

  • BDC for MIGO issue

    Hi All,
    I am trying to create BDC for MIGO T-code.But in recording part i am facing some problem
    recording steps : 1 .I am putting putting Purchasing Document Number.
                             2. Press enter.
                             3  Delivery Note
                             4. Bill of lading
                             5. GR/GI Slip No
                            6.  then in second part of screen i select batch tab and click on classification here i am
                                 geeting problem in normal way when we click this classification button new screen open in which we put values and then new batch is create but in recording after click on classification
    that screen is not coming so please can any body tell  how can i populate this classification screen.
    and put my values so migo process end.
    Regards
    Ankit

    Use this code
        l_meins = 'EA'.
      l_wa_goodsmvt_header-pstng_date = sy-datum.
      l_wa_goodsmvt_header-doc_date   = sy-datum.
      l_wa_goodsmvt_item-move_type      = '555'.
      l_wa_goodsmvt_item-move_plant     = '2000'   " Receiving plant
      l_wa_goodsmvt_item-move_stloc     = '0700'.  " Receiving SLoc
      l_wa_goodsmvt_item-material       = wa_ret_order-zzmat_no.
      l_wa_goodsmvt_item-entry_qnt      = wa_ret_order-zzqty_entered.
      l_wa_goodsmvt_item-plant          = wa_ret_order-zzissu_plant. " Plant
      l_wa_goodsmvt_item-stge_loc       = wa_ret_order-zzissu_strg_loc.
      l_wa_goodsmvt_item-entry_uom      = l_meins.
      l_wa_goodsmvt_item-entry_uom_iso  = l_meins.
      l_wa_goodsmvt_item-costcenter     = wa_ret_order-kostl.
      APPEND  l_wa_goodsmvt_item TO l_i_goodsmvt_item.
      l_goodsmvt_code-gm_code      = '03'.
    * Migo posting
      CALL FUNCTION 'BAPI_GOODSMVT_CREATE'
        EXPORTING
          goodsmvt_header  = l_wa_goodsmvt_header
          goodsmvt_code    = l_goodsmvt_code
        IMPORTING
          goodsmvt_headret = l_wa_goodsmvt_headret
          materialdocument = l_materialdocument
        TABLES
          goodsmvt_item    = l_i_goodsmvt_item
          return           = l_i_return.
    * Commit the changes
      CALL FUNCTION 'BAPI_TRANSACTION_COMMIT'
        EXPORTING
          wait = c_check.
    This code is mainly for creating STO
    Thanks
    Amitava

  • BDC for MIGO-inbound delivery

    Dear Gurus,
    I want to create a BDC for GR-INBOUND DELIVERY.Is there any process that we have to upload two text files one at header level & one at item level.Pls suggest if there is any other method. 
    Regards,
    Prasad.

    1)Create a recording of inbound delivery creation if u want to create in mass.
    2) Make a note of all the filds recorded and make a excel sheet then convert it in notepad.
    3) Upload it by LSMW.

Maybe you are looking for

  • Can I use 2 ipods on 2 computers??

    I want to buy my girl a Nano, I have a Mac G4 and an iPod already. Can I use 2 ipods with 1 computer, and are they separate accounts ie different choices of music??

  • 2 Service Orders created on save

    Experts, We are trying to create service order process type by directly using the logical link "SRV-ORD-CR" from the navigation bar of IC webclient. However its creating 2 orders on save. This happens only once per session. I have debugged through EH

  • Why is my "Documents and Data" section taking up so much space on my iPhone?

    Before I updated my iPhone to iOS7, my "Other" section was giant, taking up over 4 GB! After I updated, the section split into "Other" and "Documents and Data". My "Other" section is under control now, but my "Documents and Data" section has over 3 G

  • Transform Effect and Gaussian Blur creates issues

    Here is one issue I cannot figure out how to correct. At times, I apply the Distort - Transform effect on a clip to scale up/down, etc,...then the next clip (which I dissolve to) has the Gaussain Blur applied to it. When I apply the blur the previous

  • D3dx9_42.dll error with windows 8.1

    Hi  I just got my new pc with windows 8.1 and when I try to play games (In this case with Civ 5) I get a  d3dx9_42.dll error,  I have read that you can fix this by installing the latest DirectX drivers but windows 8.1 install DirectX with windows upd