BAPI for document flow

Hi all,
I'm looking for a BAPI returning the document flow from a sales order number or an outbound delivery number.
Thanks.
Julien.

Thanks all,
Is there a RFC-enable FM to do this work ?
Otherwise, I'll read VBFA table with BBP_RFC_READ_TABLE, but I'm firstly looking for an easier and more reliable RFC.
Regards,
Julien

Similar Messages

  • Table for Document flow

    Hi,
    I have a Sales Order. For this Sales Order i Created a Puchase Order.I made a Goods Reciept and an Account Document is created. Can any one tell the table where i can see the Document flow for this Order? I tried VBFA...but i can see only Purchase Order against the Sales Order.Thanks in Advance.
    Challa.

    VBFA is document flow for SD.
    To find receipt for purchase order, look at EKBE with key purchase order Nr and event type VGABE = '1' Goods receipt
    Then to find accounting document, you need to look to BKPF header table with keys AWTYP Reference procedure 'MKPF' and AWKEY Object key (Nr + year)
    Regards

  • BAPI for document tab of business partner

    In Business Partner we have Documents tab. At document tab We can attach some URL
    or some document. Please tell me the BAPI for this functionality.

    Hi Anupam,
    FM SKWV_KWUI_DOC_CREATE requires PACKAGE_ID as mandatory Import Parameter. Do you know how to determine its' value and what does this parameter represent?
    Thank you in advance,
    Maro

  • Step by step aproach for Document flow tree creation in Standard component

    Hi All,
    Can any one pls help in providing the steps i need to follow to create Document flow Tree using custom component in standard Opportunity/Quotation document.
    i Have created a component and assigned this component view as assignment block in Standard Component...
    but i would require the step -by-step ( Alogorithm kind off ) to extract the data flow from quotation document say to the creation of document flow ( tree with icons ) ..
    ANy help is appreciated !!!!

    Hi All,
    Can any one pls help in providing the steps i need to follow to create Document flow Tree using custom component in standard Opportunity/Quotation document.
    i Have created a component and assigned this component view as assignment block in Standard Component...
    but i would require the step -by-step ( Alogorithm kind off ) to extract the data flow from quotation document say to the creation of document flow ( tree with icons ) ..
    ANy help is appreciated !!!!

  • BAPI for Cash Flow of TM02

    Hi, experts
      Which BAPI or Function Module can change the field 'Pymnt amt PyC(+/-)' of Cash Flow tab
      in the tcode 'TM02'?
      Thanks you very much!

    HI
    these are BAPI's
    BAPI_FTR_CFT_CREATE Create Cash Flow-Dependent Transaction
    BAPI_FTR_CFT_CHANGE Change Cash Flow-Dependent Transaction
    BAPI_FTR_CFT_FLOW_CHANGE  Change Financial Flow
    BAPI_FTR_CFT_FLOW_CREATE Create Financial Flow
    BAPI_FTR_CFT_FLOW_DELETE  Delete Cash Flow
    What do you want do you want BADi or BAPI
    Regards
    Pavan

  • Function module for document flow

    Hi,
    I am developing a report on sales.
    i need to display the delivery and billing status of the sale order in the report.
    Is there any function module to get both the delivery and billing status for the input parameter sale order number.....?
    Thanks in advance....
    Raghav

    hi , check the code
    REPORT ZEX2  MESSAGE-ID arc NO STANDARD PAGE HEADING.
    Tables :kna1,vbak.
    SELECT-OPTIONS : so_vkorg FOR  vbak-vkorg OBLIGATORY,
                     so_vtweg FOR  vbak-vtweg OBLIGATORY,
                     so_spart FOR  vbak-spart,
                     so_kunnr FOR  kna1-kunnr.
    DATA : BEGIN OF sales_open OCCURS 0 ,
           vbeln LIKE vbak-vbeln,
           auart LIKE vbak-auart,
           kunnr LIKE kna1-kunnr,
           bstnk LIKE vbak-bstnk,
           lfstk LIKE vbuk-lfstk,
           fkstk LIKE vbuk-fkstk,
           gbstk LIKE vbuk-gbstk,
           END OF sales_open.
    DATA : BEGIN OF itm_sales OCCURS 0,
           vbeln LIKE vbap-vbeln,
           posnr LIKE vbap-posnr,
           matnr LIKE vbap-matnr,
           lfsta LIKE vbup-lfsta,
           lfgsa LIKE vbup-lfgsa,
           fksta LIKE vbup-fksta,
           fksaa LIKE vbup-fksaa,
           gbsta LIKE vbup-gbsta,
           END OF itm_sales.
    DATA : l_kunnr LIKE kna1-kunnr,
           l_vkorg LIKE vbak-vkorg,
           l_vtweg LIKE vbak-vtweg,
           l_spart LIKE vbak-spart.
    DATA: v_statusl(20) TYPE c,
          v_statusb(20) TYPE c,
          v_statusf(20) TYPE c,
          v_statusg(20) TYPE c,
          v_status(20) TYPE c,
          v_field(1) TYPE c.
    **Selection Screen Validations.
    AT SELECTION-SCREEN.
      PERFORM validations.
    *&      Form  Validations
          text
    -->  p1        text
    <--  p2        text
    FORM validations.
    **Customer
      IF NOT so_kunnr[] IS INITIAL.
        SELECT SINGLE kunnr INTO l_kunnr
               FROM kna1
               WHERE kunnr IN so_kunnr.
        IF sy-subrc NE 0.
          MESSAGE e002 WITH text-005.
        ENDIF.
      ENDIF.
    **Sales Organization
      IF NOT so_vkorg[] IS INITIAL.
        SELECT SINGLE vkorg INTO l_vkorg
               FROM tvko
               WHERE vkorg IN so_vkorg.
        IF sy-subrc NE 0.
          MESSAGE e003 WITH text-006.
        ENDIF.
      ENDIF.
    **Distribution Channel
      IF NOT so_vtweg[] IS INITIAL.
        SELECT SINGLE vtweg INTO l_vtweg
                FROM tvkov
                WHERE   vkorg IN so_vkorg
                 AND    vtweg IN so_vtweg.
        IF sy-subrc NE 0.
          MESSAGE e004 WITH text-007.
        ENDIF.
      ENDIF.
    **Division
      IF NOT so_spart[] IS INITIAL.
        SELECT SINGLE spart INTO l_spart
                FROM tvta
                WHERE   vkorg IN so_vkorg
                AND     vtweg IN so_vtweg
                AND     spart IN so_spart.
        IF sy-subrc NE 0.
          MESSAGE e005 WITH text-008.
        ENDIF.
      ENDIF.
    ENDFORM.                    " Validations
    Top-of-page.
    PERFORM sales_top_of_page.
    Start-of-selection.
    PERFORM sales_sel.
    *&      Form  sales_sel
          text
    -->  p1        text
    <--  p2        text
    FORM sales_sel.
    SELECT vbeln auart kunnr bstnk
         lfstk fkstk gbstk
         INTO TABLE sales_open
         FROM vbakuk
         WHERE vkorg IN so_vkorg
         AND   vtweg IN so_vtweg
         AND   spart IN so_spart
         AND   kunnr IN so_kunnr
         AND gbstk NE 'C'.
      LOOP AT sales_open.
        WRITE:/4 sy-vline,
               5 sales_open-vbeln HOTSPOT ON COLOR 2 INTENSIFIED OFF,
               16 sy-vline,
               17 sales_open-auart COLOR 2 INTENSIFIED OFF,
               27 sy-vline,
               28 sales_open-kunnr COLOR 2 INTENSIFIED OFF,
               40 sy-vline,
               41 sales_open-bstnk COLOR 2 INTENSIFIED OFF,
               55 sy-vline,
               56 sales_open-lfstk,
               76 sy-vline,
               77 sales_open-fkstk,
               96 sy-vline,
               97 sales_open-gbstk ,
               117 sy-vline.
        HIDE sales_open-vbeln .
      ENDLOOP.
    ENDFORM.                    " sales_sel
    *&      Form  sales_top_of_page
          text
    -->  p1        text
    <--  p2        text
    FORM sales_top_of_page.
      WRITE:/4 sy-uline(114),
         50 'OPEN SALES ORDERS' COLOR 7 INTENSIFIED ON .
      WRITE: /4 sy-vline,
              5 'SalesOrder' COLOR 1 ,
              16 sy-vline,
             17  'OrderType' COLOR 1,
             27  sy-vline,
             28  'Customer' COLOR 1,
             40  sy-vline,
             41  'PoNumber' COLOR 1,
             55  sy-vline,
             56  'Delivery Status' COLOR 1,
             76  sy-vline,
             77  'Billing Status' COLOR 1,
             96  sy-vline,
             97  'Processing Status' COLOR 1,
             117  sy-vline .
      WRITE:/4 sy-uline(114).
    ENDFORM.                    " sales_top_of_page
    AT LINE-SELECTION.
      SELECT       a~vbeln
                   a~posnr
                   a~matnr
                a~kwmeng
                   b~lfsta
                   b~lfgsa
                   b~fksta
                   b~fksaa
                   b~gbsta
                   INTO TABLE itm_sales
                   FROM vbap AS a JOIN vbup AS b
                   ON avbeln EQ bvbeln
                   AND aposnr EQ bposnr
                   AND b~gbsta NE 'C'
                   WHERE a~vbeln EQ sales_open-vbeln.
      IF NOT sales_open IS INITIAL.
        LOOP AT itm_sales.
          WRITE:/5  itm_sales-vbeln,
                    itm_sales-posnr,
                    itm_sales-matnr,
                    itm_sales-lfsta,
                    itm_sales-lfgsa,
                    itm_sales-fksta,
                    itm_sales-fksaa,
                    itm_sales-gbsta.
        ENDLOOP.
      ENDIF.

  • Updating Document Flow

    Hi,
    I've created an inbound delivery from an outbound delivery.  Now I need to update the document flow, and I've used the code below to do so.  My problem is when viewing the document flow for the inbound delivery via VL33N - no document flow is shown.  When I view the doc flow for the outbound delivery(VL03N), the inbound delivery shows up there. 
    Why doesn't doc flow show when viewing the inbound delivery? 
    Do I need to update document flow another way?
    LOOP AT t_ib_lips INTO s_ib_lips.
          CLEAR s_ob_lips.
          READ TABLE t_ob_lips INTO s_ob_lips WITH KEY
                                                   vgbel = s_ib_lips-vgbel
                                                   vgpos = s_ib_lips-vgpos.
    * test area for document flow
          CLEAR: s_vbfa.
          s_vbfa-mandt   = s_ib_lips-mandt.
          s_vbfa-vbelv   = s_ob_lips-vbeln.        "OB delivery number
          s_vbfa-posnv   = s_ob_lips-posnr.        "OB delivery item
          s_vbfa-vbtyp_v = is_ob_likp-vbtyp.       "OB delivery type
          s_vbfa-vbeln   = s_ib_lips-vbeln.        "IB delivery number
          s_vbfa-posnn   = s_ib_lips-posnr.        "IB delivery item
          s_vbfa-vbtyp_n = s_ib_likp-vbtyp.        "IB delivery type
          s_vbfa-rfmng   = s_ob_lips-lgmng.        "Referenced quantity
          s_vbfa-meins   = s_ob_lips-meins.        "uom
          s_vbfa-VRKME   = s_ob_lips-vrkme.
          s_vbfa-matnr   = '                 X'.
    *      s_vbfa-stufe   = '00'.
          CALL FUNCTION 'RV_XVBFA_MAINTAIN'
               EXPORTING
                    f_vorgang = 'H'
                    fvbfa     = s_vbfa
                    fvbfad    = s_vbfad
               TABLES
                    fxvbfa    = t_xvbfa
                    fyvbfa    = t_yvbfa
                    fxvbapf   = t_xvbapf.
        ENDLOOP.
    CALL FUNCTION 'RV_DOCUMENT_FLOW_UPDATE_U'
             EXPORTING
                  f_vbeln  = is_ob_likp-vbeln
                  i_status = 'H'
             TABLES
                  fxvbfa   = t_xvbfa
                  fyvbfa   = t_yvbfa.
    Below is some of the data from the entry of VBFA that is created
    VBELV         POSNV    VBELN     POSNN  VBTYP_N  VBTYP_V     STUFE
    100005128     1      180006319   1     7       J     00

    Is there a BAPI you can use instead? Neither of these FMs are released or documented. It's quite a task trying to figure out how SAP uses these FMs to update.
    Rob

  • Document flow error in Quality notication

    Hello All,
             I am seeking solution for document flow error in notification. After completing notification we are not able to find graphical network in Document flow.
    We are getting error message says "no original document in document flow"
    We have followed this process flow, notification --> create ECN --> change the material with reference to the ECN--> iqs2 complete the notification.
    Kindly share if you any solution on this error.
    Regards,
    Muthusamy

    HI,
    It is an exceptional issue I feel.
    Could you check the tables whether that particular doc. is updated or not?
    check VBFA table.
    Regards
    Suresh.

  • Inconsistency in document flow, same DMR appearing multiple times

    experts,
    While running  transaction VA43 for document flow same  resource related dmr appearing multiple times.
    Please help why this same dmr is getting displayed multiple times.
    Edited by: ronny1984 on Jun 30, 2009 2:40 PM

    Note 1049482 is valid for the following releases:
    Release Package name
    500 SAPKH50018
    600 SAPKH60011
    602 SAPKH60201
    You can check your support pack level from transaction SPAM or by clicking on:
    System -> Status. From here there is a button called "component information" in the SAP System data section. This will show you the different support pack levels. If your support pack is less than SAPKH60011 (for example SAPKH60008) then the note is applicable. "
    thanks
    G. Lakshmipathi

  • Restrict sales document flow on va03/vl02n/and any sd tcodes

    hi experts,
    Is there a way to disable or restrict the document flow button found on SD transactions such as va03 and vf03? We would provide a separate report for the docflow, a custom one.
    Thank you in advance!

    Used exit for document flow LV05CFZZ

  • Goods Reciept BAPI that updates Document Flow

    Hello,
      We are looking for a BAPI or FM that posts a goods reciept against a PO and updates document flow. Does anyone know if this exists?
      We have been using BAPI_GOODSMVT_CREATE, which will post the GR against the PO but it does not update the Doc Flow.  It is essential for Doc Flow to be updated because it posts the event in our SAP SCM EM instance. 
    Any help would be much appreciated... will award as many points possible.

    Hi,
    Check the below code:
    *********Work areas***********
    DATA : wa_mseg  type ty_mseg,
           wa_mseg1 TYPE ty_gds,
           wa_mkpf  LIKE mkpf,
           wa_lgort_sum TYPE ty_lgort_sum,
           wa_loss_data LIKE zpesloss,
           wa_zpesloss LIKE zpesloss.
    DATA : v_header   LIKE bapi2017_gm_head_01,
           v_gm_code  LIKE bapi2017_gm_code.
    DATA: wa_headret LIKE bapi2017_gm_head_ret,
          wa_matdoc TYPE bapi2017_gm_head_ret-mat_doc,
          wa_matdocyr TYPE bapi2017_gm_head_ret-doc_year.
    DATA: i_items          TYPE STANDARD TABLE OF t_items,
          i_return_goods   TYPE STANDARD TABLE OF t_return with header line,
           i_message TYPE TABLE OF bapiret2 WITH HEADER LINE.
          wa_mseg1-bwart =   '551'.
          wa_mseg1-matnr  = ws_matnr.
          wa_mseg1-umlgo  = i_mseg1-umlgo.
          wa_mseg1-lgort  = i_mseg1-lgort.
          wa_mseg1-werks  = 'SP01'.
    Header Data
        v_header-pstng_date = sy-datum.
        v_header-doc_date = sy-datum.
    Code Group
        v_gm_code-gm_code = '03'.
    ******Mandatory fields passed into BAPI***
        CLEAR i_items[].
        wa_items-material  = wa_mseg1-matnr.
        wa_items-plant     = wa_mseg1-werks.
        wa_items-stge_loc  = wa_mseg1-lgort.
        wa_items-move_type = wa_mseg1-bwart.
        wa_items-entry_qnt = wa_mseg1-lossquantity.
        wa_items-costcenter = '0000012000'.
        APPEND wa_items TO i_items.
        CALL FUNCTION 'BAPI_GOODSMVT_CREATE'
          EXPORTING
            goodsmvt_header             = v_header
            goodsmvt_code               = v_gm_code
      TESTRUN                     = ' '
       IMPORTING
         goodsmvt_headret            = wa_headret
             materialdocument        = wa_matdoc
             matdocumentyear         = wa_matdocyr
          TABLES
            goodsmvt_item               = i_items
      GOODSMVT_SERIALNUMBER       =
          return                      = i_return_goods  .
    if i_return_goods[] is not initial.
      message i001(zespur) with  i_return_goods-message.
    stop.
    endif.
    IF i_return_goods[]  IS  INITIAL .
        lws_wait = 3.
        CALL FUNCTION 'BAPI_TRANSACTION_COMMIT'
          EXPORTING
            wait = lws_wait.
          WAIT UP TO 1 SECONDS.
    endif.
    Regards,
    Prakash.

  • Document flow for contract creation

    Hi All,
        I have a requirement where i will create a follow on contract for a existing contract using a custom BDC, but i would like to have the document flow retained for the parent contract document. I would like to know if any FM or BAPI is available to maintain the document flow or any other process to do so.
    Pls treat this as an urgent requirement and reply.
    Thanks in advance

    Hi,
    I think it is quiet dangerous to add entries to VBFA tabel your self... but I saw that there is a function called RV_DOCUMENT_FLOW_ADD and RV_BILLING_INDEX_ADD. I do not know how to use it... but maybe with trial and error you can add the entries.
    What you can do is a work around by using a user-exit that show the flow you want when displaying it.
    T
    he function that show the document flow of an SD document is called RV_ORDER_FLOW_INFORMATION. In this function there are two user-exits and BADIs where you can add entries to be displayed according your logic.
    USER_EXIT für precedent docuents
      PERFORM USEREXIT_VORGAENGER.
    CALL METHOD l_sd_documentflow_exit->add_preceding_document
    UserExit + BADI for next docuemnts
    PERFORM USEREXIT_NACHFOLGER.
    CALL METHOD l_sd_documentflow_exit->add_subsequent_document

  • FM: Document flow for a sales order

    Hi,
    is there any FM, BAPI, CL to get the whole document flow for
    a given sales order.
    thanks.
    regards, Dieter

    Hi,
    look for example to BAPI_SALESORDER_GETLIST
    CALL FUNCTION 'RV_ORDER_FLOW_INFORMATION'
    Please check table VBFA. It contains all the information about document flow in SD.
    Check the example program below, it is not a function call, it is a dialog call.
    (Or)
    report zrich_0001.
    data: xvbco6 type vbco6.
    data: xvbak type vbak.
    parameters: p_vbeln type vbak-vbeln.
    clear xvbco6. clear xvbak.
    select single * from vbak into xvbak
    where vbeln = p_vbeln.
    move-corresponding xvbak to xvbco6.
    call dialog 'RV_DOCUMENT_FLOW'
    exporting
    vbco6 from xvbco6
    ivkorg from xvbak-vkorg
    ivtweg from xvbak-vtweg.
    Regards

  • Help Rgd. BAPI for Creation of Inbound delivery Document

    Hi all,
    I need a Bapi to create inbound delivery document without using PO reference. I have seen the below BAPIs. i) BAPI_IBDLV_CREATE_FROM_OBDLV, 
    ii) BAPI_GOODSMVT_CREATE. I am not sure whether they are for creating inbound delivery document without using PO reference.
    It will be of great use if anyone can give me the BAPI for the purpose and the mandatory parameters or sample test data for the BAPI.
    Thanks in Advance,
    Rakesh.

    If you create the inbound delivery->check the purchase order in the tabstrip "Confirmations" on item level. There are three fields: "Confirmation control key", "Order acknowl." and "acknowl. required".
    Ckeck if there is a value in "confirmation control key".
    You should get the same error if you try to create VL31N in dialog mode, not only by using the bapi.
    Rgds,
    JP

  • Document flow is not updated for Scheduling agreement

    Hi Gurus,
    Can you please advise on the below issue..
    Some deliveries created with reference of schedule agreement are not displayed in scheduling agreement in forecast delivery schedule under delivery tab and as well as not updated in document flow for VBFA table.
    There are two ways to create delivery with reference of Scheduling agreement , 1)  Create Delivery order (Order Type   : TAM) with reference of SA, then delivery for TAM order.
    2) we can add the line item in existing TAM order with reference of SA .
    Advance thanks for your valid points.
    Best regards,
    Venkat.

    Hi Ram,
    Thanks for the reply, there is no issue in copy control settings.
    Best regards,
    Venkat.

Maybe you are looking for

  • Trouble Setting Mac Up To Windows Network Printer

    I have an HP printer set up to an HP desktop PC, and also have my wireless router set up to that computer. The printer says it is ready to share on the PC, but I can't seem to find it on my Mac. I found it before, but it wouldn't print out anything b

  • Account not credited after payment

    My Skype name is Soxmum, Julia Thomas. I made an EFT payment on the 9th March and my account has still not been credited, usually it's credited very quickly. My order no. [removed for privacy] Payment ref no. xxxxxxxxxxxxxxx I can email you proof is

  • HELP! Script to populate a text field based off of whats picked in a dropdown on a previous page?

    Alright hopefully i can explain this good enough. I have a dropdown box that has two different options to pick from.  For example: Dropdown1 has:  Option A                          Option B On the other page I have two text fields.  TextField1 just s

  • Library Corruption Jaguar on iMac

    I am attempting to "fix" a corrupted Jaguar installation on an iMac where nearly all of the user library files were somehow moved from the user/library/ path to a user/documents/library/ path a couple of months ago. The user has absolutely NO IDEA ho

  • BAPI for creation Partial Outbound delivery

    Hi Guru Please suggest me any BAPI's for creating Partial Outbound Delivery I am working on BAPI_OUTB_DELIVERY_CREATE_SLS           but its creating full delivery Pls suggest me anythg.. Best Regards Subham Arya