PO print outs having delivery address as of storage location

Hello Experts,
What setting need to be done to have storage location address as delivery address in PO by default.

In your print program pass values plant and storage location in table TWLAD and in that table you will get address number .Use this address number in ADRC table and get address details in PO output form.
Please explain above logic to your technical team and they will do program changes.

Similar Messages

  • How to control print-out in GI Slip based on storage location

    Hi Experts,
    Presently my smartform - GI Slip is giving print out for each line item. But the requirement is: no. of print out will depend on no. of storage location, independent of line item. Since GI Slip is a collective slip hence its showing same details for each line item. The print out are first taken from MB1A and then MB90 is for reprocessing.
    How can I control the no. of printouts based on storage location
    Please help me in this issue...
    Thanks in Advance...
    Pinki.

    You have to modify your driver program,
    Ex: Loop at < internal table>
    AT NEW <storage location>
    <New-page>
    End at.
    End loop.
    The above syntax will help you to close the issue.
    Rgds,
    SR

  • Inter company STPO  delivery address showing the storage location address

    Hi Guys,
    While creating inter company STPO (different CC), the system showing delivery address is Storage location address, but i want to change plant address.
    Please help me how i can do this...
    Thanks in advance
    Regards
    Chandru.

    then delete the storage location in the PO item line.
    the storage location is the most detailed information in the PO, and it has an adress. If you procure to that storage location (that has a different address to your plant adress) then it is logic and makes a lot of sense that your supplier sends the goods to this location and not to an address where the material is not needed.

  • Print out every delivery

    Dear All.
    Till this day the duty-form for a company were performed through a
    special Form Program, it is performed via processing routines.
    The first Form Routine's name is entry.
    Form was printed-out for each Transport up to now.
    Current Requirements are for next time as follows:
    Printing out one form for every delivery (shipment) instead of
    for each Transport as so far. Please notice one Transport may
    consist of many deliveries (Shipment). 1 Transport : n Shipment.
    DATA:
          lc_wa_usrdata  TYPE /Z2a/ty_lw_usrdata.
    INCLUDE rvadtabl.
    SET EXTENDED CHECK OFF.
    TABLES: vbpla, thead, ttxer, ttxit, t005, vbddl, stxh, sadr."SADR40A
    INCLUDE vttkdata.                      "Shipment Header
    INCLUDE vttsdata.                      "Shipment Segment
    INCLUDE vttpdata.                      "Shipment Items
    INCLUDE vbpadata.                      "Partner
    INCLUDE vtfadata.                      "Flow
    INCLUDE sadrdata.                      "Address
    INCLUDE vtlfdata.                      "Delivery Selection
    INCLUDE vsedata.                       "shipping units
    INCLUDE rv56acom.                      "I/O-Structure
    SET EXTENDED CHECK ON.
    TABLES: /Z2a/tv_schein.
    FORM entry USING return_code us_screen.
      DATA: lf_retcode TYPE sy-subrc.
      screen = us_screen.
      PERFORM processing USING    us_screen
                         CHANGING lf_retcode.
      IF lf_retcode NE 0.
        return_code = 1.
      ELSE.
        return_code = 0.
      ENDIF.
    ENDFORM.
    FORM processing USING    proc_screen
                    CHANGING cf_retcode.
      DATA: ls_print_data_to_read TYPE ledlv_print_data_to_read.
      DATA: ls_dlv_delnote        TYPE ledlv_delnote.
      DATA: lf_fm_name            TYPE rs38l_fnam.
      DATA: ls_control_param      TYPE ssfctrlop.
      DATA: ls_composer_param     TYPE ssfcompop.
      DATA: ls_recipient          TYPE swotobjid.
      DATA: ls_sender             TYPE swotobjid.
      DATA: lf_formname           TYPE tdsfname.
      DATA: ls_addr_key           LIKE addr_key.
      DATA: ls_header             LIKE /Z2a/ss_pv_kopf.
      DATA: tb_daten              LIKE /Z2a/ss_pv_daten OCCURS 1.
      DATA: lc_va_lfnr            TYPE nrlevel.
      DATA: lc_va_year            TYPE char4.
      DATA: lc_va_keyseg_pv       TYPE /dca/p000_keyseg.
      DATA: lc_tb_bwdat_pv        TYPE /dca/p000_ty_tb_bwdat.
      DATA: lc_wa_bwdat_pv        TYPE /dca/p000_ty_wa_bwdat.
      DATA: lc_wa_bwm_res_pv      TYPE /Z2a/dat_cu_pvschein.
      DATA: lc_va_lifnr           TYPE kunnr.
      DATA: lc_va_nr              TYPE nrnr.
      DATA: lc_va_anz             TYPE /Z2a/anz_pv.
      DATA: lc_va_no              TYPE /Z2a/anz_kein_pv.
      DATA: lc_wa_pvschein        LIKE /Z2a/tv_schein.
      DATA: lc_va_line            LIKE sy-tabix.
      DATA: lc_va_flag_zoll       TYPE segal,
            lc_va_rqident         TYPE rspoid,
            lc_va_vsart           TYPE vsarttr,
            lc_va_tknum           TYPE tknum.
      DATA: lc_va_obj             TYPE nrobj.
      DATA: lc_va_printer         TYPE rspopname.
      DATA: lc_va_pv_kz           TYPE char4.
      DATA: lc_va_tplst           TYPE tplst.
    * SmartForm from customizing table TNAPR
      lf_formname = tnapr-sform.
    * determine print data
      PERFORM set_print_data_to_read USING    lf_formname
                                     CHANGING ls_print_data_to_read
                                     cf_retcode.
      IF cf_retcode = 0.
    * select print data
        PERFORM get_data_pv TABLES   tb_daten
                            CHANGING ls_header
                                     lc_va_flag_zoll
                                     lc_va_vsart
                                     lc_va_tplst
                                     cf_retcode.
      ENDIF.
      lc_va_tknum = nast-objky.
      IF cf_retcode = 0.
      ELSE.
        PERFORM protocol_nast_update.
        cf_retcode = 4.
        EXIT.
      ENDIF.
      IF cf_retcode = 0.
    * determine smartform function module for delivery note
        CALL FUNCTION 'SSF_FUNCTION_MODULE_NAME'
             EXPORTING  formname           = lf_formname
             IMPORTING  fm_name            = lf_fm_name
             EXCEPTIONS no_form            = 1
                        no_function_module = 2
                        OTHERS             = 3.
        IF sy-subrc <> 0.
        ENDIF.
      ENDIF.
      DESCRIBE TABLE tb_daten LINES lc_va_line.
      IF lc_va_line <> 0.
        lc_va_pv_kz = 'JA'.
        SELECT SINGLE lifnr
          FROM vtpa
          INTO lc_va_lifnr
         WHERE vbeln = nast-objky
           AND parvw = 'YL'.
        lc_va_keyseg_pv = ls_header-kunnr.
        lc_va_keyseg_pv+10(10) = lc_va_lifnr.
        lc_va_keyseg_pv+20(2)  = lc_va_vsart.
        lc_va_keyseg_pv+22(4)  = lc_va_pv_kz.
        CALL FUNCTION '/ZTR/P000_MCDATA_FROM_'
             EXPORTING
                  cv_va_keytyp = '/Z2a/KEY_CU_PVSCHEIN'
                  cv_va_keyseg = lc_va_keyseg_pv
             TABLES
                  cr_tb_bwdat  = lc_tb_bwdat_pv.
        IF lc_tb_bwdat_pv[] IS INITIAL.
          cf_retcode = 4.
        ELSE.
          LOOP AT lc_tb_bwdat_pv INTO lc_wa_bwdat_pv.
            lc_wa_bwm_res_pv = lc_wa_bwdat_pv-datseg.
            lc_va_obj = lc_wa_bwm_res_pv(10).
            lc_va_nr  = lc_wa_bwm_res_pv+10(2).
            lc_va_anz = lc_wa_bwm_res_pv+12(8).
            lc_va_printer  = lc_wa_bwm_res_pv+20(4).
            SELECT SINGLE pvno
              FROM /Z2a/tv_schein
              INTO lc_va_lfnr
             WHERE tknum = nast-objky.
            IF sy-subrc = 0.
            ELSE.
              CALL FUNCTION 'NUMBER_GET_NEXT'
                EXPORTING
              nr_range_nr                   = lc_va_nr
              object                        = lc_va_obj
               IMPORTING
                 number                     = lc_va_lfnr
              IF sy-subrc <> 0.
              ENDIF.
            ENDIF.
          ENDLOOP.
        ENDIF.
    *   call smartform delivery note
        ls_composer_param-tddest = lc_va_printer.
    *    ls_control_param-device  = lc_va_printer.
        lc_va_year = sy-datum(4).
        PERFORM set_print_param USING    ls_addr_key
                                         lc_va_lfnr
                                CHANGING ls_control_param
                                         ls_composer_param
                                         ls_recipient
                                         ls_sender
                                         cf_retcode.
        lc_wa_usrdata-mandt  = sy-mandt.
        lc_wa_usrdata-udate  = sy-datum.
        lc_wa_usrdata-uzeit  = sy-uzeit.
        lc_wa_usrdata-usr    = sy-uname.
        lc_wa_usrdata-sysid  = sy-sysid.
        DO lc_va_anz TIMES.
          CALL FUNCTION lf_fm_name
               EXPORTING
                        archive_index        = toa_dara
                        archive_parameters   = arc_params
                        control_parameters   = ls_control_param
                        mail_recipient       = ls_recipient
                        mail_sender          = ls_sender
                        output_options       = ls_composer_param
                        user_settings        = ' '
                        ls_header            = ls_header
                        lc_va_lfnr           = lc_va_lfnr
                        lc_va_year           = lc_va_year
                        lc_va_tplst          = lc_va_tplst
                        lc_wa_usrdata        = lc_wa_usrdata
              TABLES
                        tb_daten             = tb_daten
             EXCEPTIONS formatting_error     = 1
                        internal_error       = 2
                        send_error           = 3
                        user_canceled        = 4
                        OTHERS               = 5.
          IF sy-subrc <> 0.
          ENDIF.
        ENDDO.
      ELSE.
        lc_va_pv_kz = 'NEIN'.
        SELECT SINGLE lifnr
          FROM vtpa
          INTO lc_va_lifnr
         WHERE vbeln = nast-objky
           AND parvw = 'YL'.
        lc_va_keyseg_pv = ls_header-kunnr.
        lc_va_keyseg_pv+10(10) = lc_va_lifnr.
        lc_va_keyseg_pv+20(2)  = lc_va_vsart.
        lc_va_keyseg_pv+22(4)  = lc_va_pv_kz.
        CALL FUNCTION '/ZTR/P000_MCDATA_FROM_'
             EXPORTING
                  cv_va_keytyp = '/Z2a/KEY_CU_PVSCHEIN'
                  cv_va_keyseg = lc_va_keyseg_pv
             TABLES
                  cr_tb_bwdat  = lc_tb_bwdat_pv.
        IF lc_tb_bwdat_pv[] IS INITIAL.
          cf_retcode = 4.
        ELSE.
          LOOP AT lc_tb_bwdat_pv INTO lc_wa_bwdat_pv.
            lc_wa_bwm_res_pv = lc_wa_bwdat_pv-datseg.
            lc_va_obj = lc_wa_bwm_res_pv(10).
            lc_va_nr  = lc_wa_bwm_res_pv+10(2).
            lc_va_anz = lc_wa_bwm_res_pv+12(8).
            lc_va_printer  = lc_wa_bwm_res_pv+20(4).
            SELECT SINGLE pvno
              FROM /Z2a/tv_schein
              INTO lc_va_lfnr
             WHERE tknum = nast-objky.
            IF sy-subrc = 0.
              UPDATE /Z2a/tv_schein
              SET flag_pv = ' '
              WHERE tknum = nast-objky.
            ELSE.
    * laufende nummer füllen, bei keinen PV-Teilen Nummernkreis 99
              CALL FUNCTION 'NUMBER_GET_NEXT'
                EXPORTING
              nr_range_nr                   = lc_va_nr
              object                        = lc_va_obj
    *    QUANTITY                      = '1'
    *   SUBOBJECT                     = ' '
    *   TOYEAR                        = '0000'
    *   IGNORE_BUFFER                 = ' '
               IMPORTING
                 number                     = lc_va_lfnr
    *   QUANTITY                      =
    *   RETURNCODE                    =
    * EXCEPTIONS
    *   INTERVAL_NOT_FOUND            = 1
    *   NUMBER_RANGE_NOT_INTERN       = 2
    *   OBJECT_NOT_FOUND              = 3
    *   QUANTITY_IS_0                 = 4
    *   QUANTITY_IS_NOT_1             = 5
    *   INTERVAL_OVERFLOW             = 6
    *   BUFFER_OVERFLOW               = 7
    *   OTHERS                        = 8
              IF sy-subrc <> 0.
    * MESSAGE ID SY-MSGID TYPE SY-MSGTY NUMBER SY-MSGNO
    *         WITH SY-MSGV1 SY-MSGV2 SY-MSGV3 SY-MSGV4.
              ENDIF.
            ENDIF.
          ENDLOOP.
          lc_va_year = sy-datum(4).
          ls_composer_param-tddest = lc_va_printer.
          PERFORM set_print_param USING    ls_addr_key
                                           lc_va_lfnr
                                  CHANGING ls_control_param
                                           ls_composer_param
                                           ls_recipient
                                           ls_sender
                                           cf_retcode.
          lc_wa_usrdata-mandt  = sy-mandt.
          lc_wa_usrdata-udate  = sy-datum.
          lc_wa_usrdata-uzeit  = sy-uzeit.
          lc_wa_usrdata-usr    = sy-uname.
          lc_wa_usrdata-sysid  = sy-sysid.
          DO lc_va_anz TIMES.
            CALL FUNCTION lf_fm_name
                 EXPORTING
                          archive_index        = toa_dara
                          archive_parameters   = arc_params
                          control_parameters   = ls_control_param
                          mail_recipient       = ls_recipient
                          mail_sender          = ls_sender
                          output_options       = ls_composer_param
                          user_settings        = ' '
                          ls_header            = ls_header
                          lc_va_lfnr           = lc_va_lfnr
                          lc_va_year           = lc_va_year
                          lc_va_tplst          = lc_va_tplst
                          lc_wa_usrdata        = lc_wa_usrdata
                TABLES
                          tb_daten             = tb_daten
               EXCEPTIONS formatting_error     = 1
                          internal_error       = 2
                          send_error           = 3
                          user_canceled        = 4
                          OTHERS               = 5.
            IF sy-subrc <> 0.
            ENDIF.
          ENDDO.
        ENDIF.
      ENDIF.
      SELECT SINGLE *
        FROM /Z2a/tv_schein
        INTO lc_wa_pvschein
       WHERE tknum = nast-objky.
      IF sy-subrc = 0.
      ELSE.
        IF NOT lc_va_lfnr IS INITIAL.
          lc_wa_pvschein-mandt = sy-mandt.
          lc_wa_pvschein-tknum = nast-objky.
          INSERT INTO /Z2a/tv_schein
          VALUES lc_wa_pvschein.
          UPDATE /Z2a/tv_schein SET
          pvno  = lc_va_lfnr
          vsart = lc_va_vsart
          exti1 = ls_header-schiffname
          signi = ls_header-siegel
          flag_zoll = lc_va_flag_zoll
          exti2 = ls_header-contnr
          lifex = ls_header-mbcnr
          dalen = ls_header-dalen
          dptbg = ls_header-dptbg
          kunnr = ls_header-kunnr
          add03 = ls_header-add03
          parnr = lc_va_lifnr
          datum_druck = sy-datum
          uzeit_druck = sy-uzeit
          ernam_druck = sy-ucomm
          WHERE tknum = nast-objky.
          IF tb_daten IS INITIAL.
            UPDATE /Z2a/tv_schein SET
           flag_pv = ' '
           WHERE tknum = nast-objky.
          ELSE.
            UPDATE /Z2a/tv_schein SET
            flag_pv = 'X'.
          ENDIF.
        ENDIF.
      ENDIF.
    * get SmartForm protocoll and store it in the NAST protocoll
    * PERFORM ADD_SMFRM_PROT.                       DEL_HP_335958
    ENDFORM.
    FORM get_data_pv TABLES   lc_tb_daten
                     CHANGING cs_header TYPE /Z2a/ss_pv_kopf
                              lc_va_flag_zoll TYPE segal
                              lc_va_vsart TYPE vsarttr
                              lc_va_tplst TYPE tplst
                              cf_retcode.
      TYPES: BEGIN OF ty_wa_vbeln,
             vbeln TYPE vbeln_vl,
             END OF ty_wa_vbeln,
             ty_tb_vbeln TYPE STANDARD TABLE OF ty_wa_vbeln
                         WITH DEFAULT KEY
                         INITIAL SIZE 0,
             ty_wa_lips LIKE lips,
             ty_tb_lips TYPE STANDARD TABLE OF ty_wa_lips
                        WITH DEFAULT KEY
                        INITIAL SIZE 0.
      DATA: lc_tb_cond  LIKE /Z2a/ss_pv_daten OCCURS 1.
      DATA: lc_wa_daten TYPE /Z2a/ss_pv_daten.
      DATA: lc_wa_cond  TYPE /Z2a/ss_pv_daten.
      DATA: lc_va_tknum TYPE tknum,
            lc_tb_lips  TYPE ty_tb_lips,
            lc_wa_lips  TYPE ty_wa_lips,
            lc_va_kunnr TYPE kunnr,
            lc_va_pvvkz TYPE /Z2a/pvvkz,
            lc_va_exprf TYPE exprf,
            lc_va_matnr TYPE matnr,
            lc_va_menge TYPE lfimg.
      DATA: lc_tb_vbeln TYPE ty_tb_vbeln,
            lc_wa_vbeln TYPE ty_wa_vbeln,
            lc_va_land1 TYPE land1,
            lc_va_lifnr TYPE lifnr.
      DATA: lc_va_exnum TYPE exnum.
      DATA: lc_va_keyseg TYPE /dca/p000_keyseg.
      DATA: lc_tb_bwdat  TYPE /dca/p000_ty_tb_bwdat.
      DATA: lc_wa_bwdat  TYPE /dca/p000_ty_wa_bwdat.
      DATA: lc_wa_bwm_result TYPE /Z2a/dat_cu_pvabwicklung.
      DATA language LIKE nast-spras.
      DATA shipment_number LIKE vttk-tknum.
      CLEAR cf_retcode.
    * get data
      language = nast-spras.
      shipment_number = nast-objky.
      CALL FUNCTION 'RV_SHIPMENT_PRINT_VIEW'
           EXPORTING
                shipment_number     = shipment_number
                option_tvtk         = 'X'  "Shipmenttype J/N
                option_ttds         = 'X'  "Disposition J/N
                language            = language
                option_items        = 'X'  "Transport Items J/N
                option_segments     = 'X'  "Transport Segments J/N
                option_partners     = 'X'  "Partners J/N
                option_sales_orders = 'X'  "Sales orders J/N
                option_export_data  = 'X'  "Export data J/N
                option_packages     = 'X'  "Packages J/N
                option_flow         = ' '  "Flow J/N
                option_no_refresh   = ' '  "Refresh Tables J/N
           IMPORTING
                f_vttkvb            = vttkvb  "Shipment Header
                f_tvtk              = tvtk  "Shipmenttype
                f_tvtkt             = tvtkt  "Description Shipmenttype
                f_ttds              = ttds  "Disposition
                f_ttdst             = ttdst  "Description Disposition
                f_vbpla             = vbpla  "Packages
           TABLES
                f_vttp              = xvttp  "Shipment Items
                f_trlk              = slk  "Delivery
                f_trlp              = slp  "Delivery Item
                f_vtts              = xvtts  "Shipment Segments
                f_vtsp              = xvtsp  "Segments/Items
                f_vbpa              = xvbpa  "Partner
                f_vbadr             = xvbadr  "Address
                f_vtfa              = xvtfa  "Flow
                f_vbplk             = xvbplk  "Shipment Unit Header
                f_vbplp             = xvbplp  "Shipment Unit
                f_vbpls             = xvbpls  "Shipment Unit Sum
           EXCEPTIONS
                not_found           = 1.
      cs_header-tknum      = nast-objky.
      cs_header-schiffname = vttkvb-exti1.
      cs_header-abfahrt    = vttkvb-dptbg.
      cs_header-contnr     = vttkvb-exti2.
      cs_header-normt      = vttkvb-add01.
      cs_header-siegel     = vttkvb-signi.
      cs_header-gewbr      = vttkvb-text2.
      cs_header-gewnt      = vttkvb-text3.
      cs_header-dalen      = vttkvb-dalen.
      cs_header-dptbg      = vttkvb-dptbg.
      cs_header-add03      = vttkvb-add03.
      lc_va_tplst          = vttkvb-tplst.
      lc_va_vsart = vttkvb-vsart.
      SELECT vbeln
        FROM vttp
        INTO TABLE lc_tb_vbeln
       WHERE tknum = lc_va_tknum.
      LOOP AT lc_tb_vbeln INTO lc_wa_vbeln.
        SELECT SINGLE kunnr lifex
          FROM likp
          INTO (lc_va_kunnr, cs_header-mbcnr)
         WHERE vbeln = lc_wa_vbeln-vbeln.
        SELECT *
          FROM lips
          INTO TABLE lc_tb_lips
         WHERE vbeln = lc_wa_vbeln-vbeln.
      ENDLOOP.
      LOOP AT lc_tb_lips INTO lc_wa_lips.
        SELECT SINGLE pvvkz
          FROM /Z2a/ldm_kun
          INTO lc_va_pvvkz
         WHERE kunnr = lc_va_kunnr.
        IF lc_va_pvvkz NE 'X'.
          cf_retcode = 4.
          EXIT.
        ELSE.
          SELECT SINGLE exnum segal
           FROM eikp
           INTO (lc_va_exnum, lc_va_flag_zoll)
          WHERE refnr = lc_wa_lips-vbeln.
          SELECT SINGLE exprf
            FROM eipo
            INTO lc_va_exprf
           WHERE exnum = lc_va_exnum
             AND expos = lc_wa_lips-posnr.
          lc_va_keyseg = lc_va_exprf.
          CALL FUNCTION '/ZTR/P000_MCDATA_FROM_'
               EXPORTING
                    cv_va_keytyp = '/Z2a/KEY_CU_PVABWICKLUNG'
                    cv_va_keyseg = lc_va_keyseg
               TABLES
                    cr_tb_bwdat  = lc_tb_bwdat.
          IF NOT lc_tb_bwdat[] IS INITIAL.
            LOOP AT lc_tb_bwdat INTO lc_wa_bwdat.
              lc_wa_bwm_result = lc_wa_bwdat-datseg.
              IF lc_wa_bwm_result-pv_relevant = 'X'.
    * Kumulieren
                lc_wa_cond-matnr = lc_wa_lips-matnr.
                SELECT SINGLE maktx
                  FROM makt
                  INTO lc_wa_cond-arktx
                 WHERE matnr = lc_wa_lips-matnr
                   AND spras = 'DE'.
                lc_wa_cond-menge = lc_wa_lips-lfimg.
                lc_wa_cond-me    = lc_wa_lips-meins.
                COLLECT lc_wa_cond INTO lc_tb_cond.
              ENDIF.
            ENDLOOP.
          ENDIF.
        ENDIF.
      ENDLOOP.
      cs_header-kunnr = lc_va_kunnr.
      SELECT SINGLE name1 name2 land1
        INTO (cs_header-name1,
              cs_header-name2,
              lc_va_land1)
         FROM kna1
        WHERE kunnr = lc_va_kunnr.
      SELECT SINGLE landx
        INTO cs_header-land
        FROM t005t
       WHERE spras = sy-langu
         AND land1 = lc_va_land1.
    * Sortieren Aufsteigend nach Materialnr
      SORT lc_tb_cond ASCENDING BY matnr.
    * Übergabe an Ausgabetabelle
      LOOP AT lc_tb_cond INTO lc_wa_cond.
        MOVE-CORRESPONDING lc_wa_cond TO lc_wa_daten.
        APPEND lc_wa_daten TO lc_tb_daten.
      ENDLOOP.
    ENDFORM.                    " get_data_spat
    FORM set_print_data_to_read
             USING    if_formname LIKE tnapr-sform
             CHANGING cs_print_data_to_read TYPE ledlv_print_data_to_read
                      cf_retcode.
      FIELD-SYMBOLS: <fs_print_data_to_read> TYPE xfeld.
      DATA: lt_fieldlist TYPE tsffields.
      DATA: ls_fieldlist TYPE LINE OF tsffields.
      DATA: lf_field1 TYPE LINE OF tsffields.
      DATA: lf_field2 TYPE LINE OF tsffields.
      DATA: lf_field3 TYPE LINE OF tsffields.
      CALL FUNCTION 'SSF_FIELD_LIST'
        EXPORTING
          formname                = if_formname
    *     VARIANT                 = ' '
        IMPORTING
          fieldlist               = lt_fieldlist
       EXCEPTIONS
         no_form                  = 1
         no_function_module       = 2
         OTHERS                   = 3.
      IF sy-subrc <> 0.
        cf_retcode = sy-subrc.
        CLEAR lt_fieldlist.
      ELSE.
    * set print data requirements
        LOOP AT lt_fieldlist INTO ls_fieldlist.
          SPLIT ls_fieldlist AT '-' INTO lf_field1 lf_field2 lf_field3.
    * <<<< START_OF_INSERTION_HP_350342 >>>>
          IF lf_field1 = 'IS_DLV_DELNOTE' AND lf_field2 = 'IT_SERNR'.
            lf_field2 = 'IT_SERNO'.
          ENDIF.
    * <<<< END_OF_INSERTION_HP_350342 >>>>
          ASSIGN COMPONENT lf_field2 OF STRUCTURE
                           cs_print_data_to_read TO <fs_print_data_to_read>.
          IF sy-subrc = 0.
            <fs_print_data_to_read> = 'X'.
          ENDIF.
        ENDLOOP.
    * header data is always required
        cs_print_data_to_read-hd_gen = 'X'.
    * adress is always required for print param
        cs_print_data_to_read-hd_adr = 'X'.
    * organisational data is always required for include texts
        cs_print_data_to_read-hd_org = 'X'.
      ENDIF.
    ENDFORM.                    " set_print_data_to_read
    *&      Form  set_print_param
    *       text
    *      -->P_LS_ADDR_KEY  text
    *      <--P_LS_CONTROL_PARAM  text
    *      <--P_LS_COMPOSER_PARAM  text
    *      <--P_LS_RECIPIENT  text
    *      <--P_LS_SENDER  text
    *      <--P_CF_RETCODE  text
    FORM set_print_param USING    is_addr_key LIKE addr_key
    *                              lc_va_tknum
                                  lc_va_lfnr TYPE nrlevel
                         CHANGING cs_control_param TYPE ssfctrlop
                                  cs_composer_param TYPE ssfcompop
                                  cs_recipient TYPE  swotobjid
                                  cs_sender TYPE  swotobjid
                                  cf_retcode TYPE sy-subrc.
      DATA: ls_itcpo     TYPE itcpo.
      DATA: lf_repid     TYPE sy-repid.
      DATA: lf_device    TYPE tddevice.
      DATA: ls_recipient TYPE swotobjid.
      DATA: ls_sender    TYPE swotobjid.
      DATA: lc_va_suffix TYPE rspo2name.
      lf_repid = sy-repid.
      CALL FUNCTION 'WFMC_PREPARE_SMART_FORM'
           EXPORTING
                pi_nast       = nast
                pi_addr_key   = is_addr_key
                pi_repid      = lf_repid
           IMPORTING
                pe_returncode = cf_retcode
                pe_itcpo      = ls_itcpo
                pe_device     = lf_device
                pe_recipient  = cs_recipient
                pe_sender     = cs_sender.
      SHIFT lc_va_lfnr LEFT DELETING LEADING '0'.
      CONCATENATE 'PV' lc_va_lfnr INTO lc_va_suffix.
      IF cf_retcode = 0.
        MOVE-CORRESPONDING ls_itcpo TO cs_composer_param.
        cs_composer_param-tdsuffix2   = lc_va_suffix.
        cs_control_param-device      = lf_device.
        cs_control_param-no_dialog   = 'X'.
        cs_control_param-preview     = screen.
        cs_control_param-getotf      = ls_itcpo-tdgetotf.
        cs_control_param-langu       = nast-spras.
      ENDIF.
    ENDFORM.                    " set_print_param
    FORM protocol_nast_update.
      CALL FUNCTION 'NAST_PROTOCOL_UPDATE'
           EXPORTING
                msg_arbgb = '/Z2a/PVSCHEIN'
                msg_nr    = '001'
                msg_ty    = 'E'
    *              MSG_V2    = SYST-MSGV2
    *              MSG_V3    = SYST-MSGV3
    *              MSG_V4    = SYST-MSGV4
    *              MSG_V1    = SYST-MSGV1
           EXCEPTIONS
                OTHERS    = 1.
    ENDFORM.                   

    Hello!
    I have to customize the enclosed source code so it does the following:
    print out for each shipment (see FuBa:RV_SHIPMENT_PRINT_VIEW
    parameter slp) really seperated by for every shipment item LIKP-VBELN
    and not for the whole VTTP-TKNUM.
    The parameter "slp" must be stripted so by leaving
    of the routine "get_data_pv" has only the datas of the current
    LIKP-VBELN, and in the next step taking the next LIKP-VBELN
    and so on. Right now it performs only one time for one  VTTP-TKNUM.
    If you don't understand VTTP-TKNUM and LIKP-VBELN please refer
    to Transaction SE11.
    Reagrds
    Ilhan

  • PO print out of delivery schedule

    Hi,
    Suppose I am generating a PO , in some cases I will be giving delivery schedule for some items in item details.
    I want this to come in the print out.
    But its not coming .
    Please advise.
    regards,

    Hi
    You can include logic with the help of Developre, If information is there in EKET for Purchase order ask him to include in print.
    regards
    Srinivas

  • Inbound delivery split based on Storage Locations

    Hello,
    We are trying to create a delivery with reference to a PO, having one material but with different storage locations, one managed/linked with EWM and other managed only in ECC. Just want to know how the delivery can be distributed in EWM???
    Thanks

    Dear Mani,
    Refer link:
    Re: Integration of EWM with ECC 5.0
    Best Regards,
    Amit

  • Problem in Address update for storage location via LSMW

    I am trying to update the address of storage location thru LSMW,
    Normally when i run OX09 i get the "dialogue structure' in LHS panel but when I do the recording of OX09 in LSMW, I am not getting the "Dialogue structure" LHS panel & hence I can't go to the 'Addressees for storage location'
    How to get the ""Dialogue structure" in LHS while recording in LSMW so that I can update the address also.
    Currently my recording only takes me to the create storage location & no LHS 'dialogue structure'  for 'Addressees for storage location'
    Please give the suggestions as I its on urgent for me to update 1000 storage location.

    Dearrrrrrr Prasoooon,
    U got it Right Again!!!!!
    Thank you so much.
    I resolved with above Note & now i can happily go on leave from tomorrow.
    Salute to you!!!!!!!!

  • Stop delivery creation for perticular Storage Location

    Dear Experts
    As per scenario we have two storage location 1) packing stock and 2) Ware House stock. All delivery are create from Ware house st.loaction.as per requiremnt we want to stop Delivery creation for Packing St.location.
    Is ther any customization through which System should not Create Outbound delivery form Packing St.loaction,while doing this  rest of things sholud not affect for that S.Loaction
    Regards
    Pash@SD

    Go to SPRO-> Logistics Execution ->shipping ->picking->determine pikcing location ->assign picking location.
    Here you can remove the packing stock storage location assignment to plant/shipping point/storage conditions combination and then test.
    If this does not work, then check the path SPRO-> Logistics Execution ->shipping ->picking->define picking requirements. Here check any requirements is currently used. If so copy this routine and create a new routine to exclude the storage location (packing stock) from picking process.
    Regards,

  • Print out the delivery schedule item wise

    Hi friends..
    can any one pl tell me how to take the printout of the delivery schedules item wise.
    i have checked the ME80RN but it doesnt work for me.
    client want to print delivery schedule not SCHEDULING AGGREMENT.
    Your help will be highly appreciated..with points..
    Regards,
    Anil

    Hi,
    Hope you can create an access sequence with material as a field and create a condition record based on this...
    Bcoz mess determination takes place at header level.
    Reg,
    Deepak

  • Problem wih delivery address on print preview

    Dear experts,
    I have a problem with the delivery address on the print preview.
    When i create my PO and i attahced the storage location my delivery address in good in the PO and in the print preview.
    When i'm not attaching the storage location the delivery address in PO is the one of the plant but in the print preview i have the different address that i do not know where its comming from.
    Can you tell me which addreess in used by program as a delivery address when the storage location is not mentioned?
    I thinkits that program SAPFM06P.
    Thanks a lot for your help.

    in case of 3rd party order you have a account assignment which has the sales order number.
    execute VA03 und enter the sales order number. goto the partner tab at header level and obtain which customer number is the ship-to.
    the address for this customer number can be seen with XD03 transaction.
    you can as well check at KNA1 table to find the address number and with address number again get the address from ADRC table.

  • Different delivery address in PO

    Dear Sirs,
              We have rented a warehouse outside our plant premises for storage of goods. when we are raising PO we want to indicate the delivery address of our storage location not that of our plant.
    we want to indicate in the PO that PO is raised from our plant but the goods are to be delivered at our warhouse address.
    how this can be done in PO
    regards
    ajay

    Hi Ajay,
    This can be done easily through Tcode:MEAN (Maintain delivery address). Just go to this transaction and create ur warehouse address and save it. This will be saved with a unique address number in table adrc.
    In the purchase order, item details screen click on 'delivery address' and just input the address number in the field 'address' by clicking F4 u can select the appropriate address number (Here the address group must be ME01). Then the selected delivery address will be your warehouse which will be seen in the delivery address screen.
    Hope this helps.
    Thanks,
    Viswanath

  • BAPI_REQUISITION_CREATE is updating storage location address (global one)

    Hello Colleagues,
    We have a LN application for PR creation and is integrated with SAP. Process is PR gets transferred from LN to SAP and then PO would be created manually in SAP. Obseved couple of times that storage location address gets updated with delivery address in PR. Any pointers in this regard? Could you give me some insight about REQUISITION_ADDRDELIVERY parameter for BAPI, specially ADDR_NO.
    Thanks and Regards,
    Prasanth

    Simple rule is storage location address should not be changed from transaction data. In case item delivery address differs from storage location, it should made as local to PO. But here storage location got updated with new delivery address. Result is many POs are going to effet with this change in SLoc address. This problem found few months ago and now.

  • Tax jurisdiction from storage location address

    Hi all,
    During PO creation (ME21N), the tax jurisdiction (Invoice tab) defaults to the one set up in the plant address. Is there a way to have it default to the tax jurisdiction from the storage location address?
    Thanks.

    Charlie.,
    I am looking to add the following particulars in the PO Delivery address from the Storage location address/s
       NAME:              Title and First column already exist.
                               (To be included ) Second Column.
    Street Address : Street/House number, Postal code, City and region already present.
                             ( To be included) Jurisdiction Code and County
    Communication :  To be included ( Telephone number ) -- Ext Number
    Thanks

  • Print delivery address in a Purchase Order

    Hello,
    Could you please tell me, what I should to do for print delivery address in a purchase order?
    I need to configure or activate these fields: Name y Street/House number in the PO printed
    Thanks!!
    Best Regards,
    Mariela

    the delivery adress is storage location address, if storage location has an address and is entered in the PO.
    the delivery adress is plant address, if no storage location is entered in the PO or the storage location does not have an address.
    or the delivery address is taken directly from POs delivery adress at item detail  if maintained manually there.
    If it does not print, then you may use a customized form which is not prepared to print the address.
    If that is the case, then contact the developer of the form.

  • Plant address in print out

    Dear Experts,
    In PO, we have created two line item. In that, we have deleted one line item. This is belongs to US plant. second line item is belongs to India plant.
    Now when we are taking print out, deleted plant address is coming. We need second line item plant address in our print out.

    Hi Swathi,
              I think in Your smart form, Plant address displaying at header level. How ever it is possible to check all the plants with address and display at header level. before developing smart form, we should give logic like if first line item deleted it should check second line item , if first and second line item deleted then check third item,... like we have write code .
    Generally in one PO, we will use only one plant for all items.
    Ask your client to maintain one plant in all item or change the logic
    Regards,
    Ravindra  

Maybe you are looking for

  • Sxmb_moni error BaseRuntimeException thrown during application mapping

    Hi experts My scenario is file to idoc. Pushing xml file from ftp . The messages are going in system error in RWB. When we see in sxmb_moni I get the following error. <?xml version="1.0" encoding="UTF-8" standalone="yes" ?> - <!--  Request Message Ma

  • What am I supposed to do with these issues?

    I found this: 2013-11-29 10:49:28 +0100 Encrypted file: /Users//Downloads/AdobeFlashPlayerInstaller_11_ltrosxd_aaa_aih-2.dmg 2013-11-29 10:49:29 +0100 Encrypted file: /Users/Downloads/AdobeFlashPlayerInstaller_11_ltrosxd_aaa_aih.dmg

  • Error getting MoCA data

    Because Verizon CustSvc messed up our appointment and can't get a technician for another 8 days, I'm asking here. I have been with FiOS for a while and just a couple days ago bought a new TV to replace the one in my living room.  Never had any servic

  • You're almost there..................................

    Thats what I get when trying to open my mailbox. The page is bricked, What ever I select nothing opens. Help!!!!!

  • SQL Server 2005 Express DSN File

    I'm converting to sql server 2005, my orignal DSN file sql server 7 looked like the following [ODBC] DRIVER=SQL Server UID=sa DATABASE=PCX-MEMS-SCANS APP=Microsoft® Windows® Operating System SERVER=PCX-DATABASE the new one is SQL SERVER EXPRESS 2005