<?xml version="1.0" encoding="UTF-8"?>
<rss xmlns:content="http://purl.org/rss/1.0/modules/content/" xmlns:dc="http://purl.org/dc/elements/1.1/" xmlns:rdf="http://www.w3.org/1999/02/22-rdf-syntax-ns#" xmlns:taxo="http://purl.org/rss/1.0/modules/taxonomy/" version="2.0">
  <channel>
    <title>topic Updating Document Flow in Application Development and Automation Discussions</title>
    <link>https://community.sap.com/t5/application-development-and-automation-discussions/updating-document-flow/m-p/1402794#M194636</link>
    <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;Hi,&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;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.  &lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Why doesn't doc flow show when viewing the inbound delivery?  &lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Do I need to update document flow another way?&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;PRE&gt;&lt;CODE&gt;
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.

&lt;/CODE&gt;&lt;/PRE&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Below is some of the data from the entry of VBFA that is created&lt;/P&gt;&lt;PRE&gt;&lt;CODE&gt;
VBELV	    POSNV    VBELN     POSNN  VBTYP_N  VBTYP_V	STUFE
100005128     1      180006319   1	7       J	00

&lt;/CODE&gt;&lt;/PRE&gt;&lt;P&gt;&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
    <pubDate>Thu, 22 Jun 2006 01:22:28 GMT</pubDate>
    <dc:creator>Former Member</dc:creator>
    <dc:date>2006-06-22T01:22:28Z</dc:date>
    <item>
      <title>Updating Document Flow</title>
      <link>https://community.sap.com/t5/application-development-and-automation-discussions/updating-document-flow/m-p/1402794#M194636</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;Hi,&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;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.  &lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Why doesn't doc flow show when viewing the inbound delivery?  &lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Do I need to update document flow another way?&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;PRE&gt;&lt;CODE&gt;
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.

&lt;/CODE&gt;&lt;/PRE&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Below is some of the data from the entry of VBFA that is created&lt;/P&gt;&lt;PRE&gt;&lt;CODE&gt;
VBELV	    POSNV    VBELN     POSNN  VBTYP_N  VBTYP_V	STUFE
100005128     1      180006319   1	7       J	00

&lt;/CODE&gt;&lt;/PRE&gt;&lt;P&gt;&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Thu, 22 Jun 2006 01:22:28 GMT</pubDate>
      <guid>https://community.sap.com/t5/application-development-and-automation-discussions/updating-document-flow/m-p/1402794#M194636</guid>
      <dc:creator>Former Member</dc:creator>
      <dc:date>2006-06-22T01:22:28Z</dc:date>
    </item>
    <item>
      <title>Re: Updating Document Flow</title>
      <link>https://community.sap.com/t5/application-development-and-automation-discussions/updating-document-flow/m-p/1402795#M194637</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;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.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Rob&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Thu, 22 Jun 2006 03:07:25 GMT</pubDate>
      <guid>https://community.sap.com/t5/application-development-and-automation-discussions/updating-document-flow/m-p/1402795#M194637</guid>
      <dc:creator>Former Member</dc:creator>
      <dc:date>2006-06-22T03:07:25Z</dc:date>
    </item>
  </channel>
</rss>

