Print SapScript. urgent

Dear All ,
   How  to change the allignment of characters , for printing form from
portrait to lanscape format.(before that the form is in portrait format now i changed
it accords to landscape format but characters are printing as per portrait format
only so how to change that ) help me its urgent , i will reward the points ?

Hi
You have to allign the data completely to suit to the Landscape format
SInce previously it was in Portrait all the windows and fields were alligned accordingly
Now you have to shift them to the New format by shifting the windows and the elements/fields into new format to suit to the new requirement
You can create new Paragraph formats with new fonts, character formats etc and use them as per your display of data
Reward points for useful Answers
Regards
Anji

Similar Messages

  • Printing sapscript label using zebra printer

    Hi,
    Can anybody please help me regarding "printing sapscript label using zebra printer"?
    i hav set the following print default settings in the transaction mb90:
    output device :
    NO01
    device type: YZZX_ZEB
    but when i try to print ,i am getting error message stating that "the respective sapscript form is not active ".
    i hav also attached my print program for ur easy reference.
    ====================================================================*
    FORM open_form_slv.
    *'  Description:
    *'  Add information for the SAP spooler
    *'  Change the name of the standard customized form for Zebra print
    *'  Last Change Vers Programmer   Reason
    *1
      DATA: BEGIN OF print_infos.
              INCLUDE STRUCTURE itcpo.
      DATA: END OF print_infos.
      DATA: form_name(16) TYPE c, char1(1) TYPE c, ind_beg TYPE i.
      PERFORM itcpo_fuellen.
      MOVE-CORRESPONDING itcpo TO print_infos.
      WRITE sy-datum USING EDIT MASK '__.__.____'
                                               TO print_infos-tdcovtitle+1.
      WRITE sy-uzeit USING EDIT MASK '__:__:__'
                                              TO print_infos-tdcovtitle+12.
      CONCATENATE itcpo-tddest sy-uname ' PO'(001) ekpo-ebeln ' Doc.No'(002)
                                           mseg-mblnr print_infos-tdcovtitle
                              INTO print_infos-tdcovtitle SEPARATED BY space.
    form name from the table YZZM_GR_LABEL
      IF NOT g_fonam IS INITIAL.
        tnapr-fonam = g_fonam.
      ENDIF.
    if the used printer is a Zebra label printer, then the customized
    layout set name ???_???_XXX will be changed to ???_???_ZP
      SELECT SINGLE * FROM  tsp03d WHERE  padest  = nast-ldest.
      IF tsp03d-patype = 'YZZX_ZEB'.
        ind_beg := 15.
        WHILE ind_beg > -1.
          char1 := tnapr-fonam+ind_beg.     " substr(tnapr-fonam,ind_beg,1)
          IF char1 = '_'.
            form_name := tnapr-fonam(ind_beg).
            CONCATENATE form_name '_ZP' INTO tnapr-fonam.
            EXIT.
          ENDIF.
          ind_beg := ind_beg - 1.
        ENDWHILE.
      ENDIF.
      CALL FUNCTION 'OPEN_FORM'
        EXPORTING
          device   = 'PRINTER'
          language = language
          OPTIONS  = print_infos
          form     = tnapr-fonam
          dialog   = ' '.
      x_open := x.
      IF mseg-weanz = 0. mseg-weanz = 1. ENDIF.
      IF syst-tcode <> 'MB90'  AND  NOT g_flag_popup IS INITIAL.
    check for requirement of printing label and ask for gr-quantities (popup)
        SELECT SINGLE * FROM yzzm_gr_quantity WHERE ebeln = mseg-ebeln.
        CLEAR yzzm_gr_quantity-no_popup.
      ELSE.
    and ask not for gr-quantities
        IF syst-tcode = 'MB90'.
          yzzm_gr_quantity-erfmg := mseg-menge.
        ELSE.
          yzzm_gr_quantity-erfmg := mseg-menge / mseg-weanz.
        ENDIF.
        yzzm_gr_quantity-no_popup := x.
      ENDIF.
    determination inspection lot number
      CLEAR qals-prueflos.
      SELECT SINGLE * FROM qals WHERE mblnr = mseg-mblnr
                           AND zeile = mseg-zeile
                           AND mjahr = mseg-mjahr.
    determination vendor batch
      CLEAR mch1-licha.
      SELECT SINGLE * FROM mch1 INTO mch1 WHERE matnr = mseg-matnr
                                            AND charg = mseg-charg.
    ENDFORM.                    "open_form_label
    =================================================================== *
    FORM we01_print_slv.
    *'  Description:
    *'  print out of hazardous symbol
    *'  controls the Zebra printer
    *'  Last Change Vers Programmer   Reason
    *****26.09.2007 Starts
      DATA: l_objky TYPE nast-objky,"Object key
            l_vstat TYPE nast-vstat. "Processing status of message
    *****26.09.2007 Starts
      TABLES: mgef, t300.
      FIELD-SYMBOLS: .
      DATA: aux_index LIKE sy-index.
      DATA: count_haz_sym, position TYPE n, zw TYPE p DECIMALS 1.
      DATA: aux_value(5) TYPE c.
      DATA: txt(10) TYPE c, pos(5) TYPE c.
      t001w-werks = r_werks.
      t001w-name1 = r_name1.
      PERFORM read_address.
    *2
      SELECT SINGLE * FROM ekpo WHERE ebeln = mseg-ebeln
                                  AND ebelp = mseg-ebelp.
      CLEAR mara-stoff.
      SELECT SINGLE stoff INTO mara-stoff FROM mara WHERE matnr = mseg-matnr.
      IF NOT mara-stoff IS INITIAL.
        CLEAR t300.
        SELECT SINGLE * FROM t300 WHERE lgnum = mseg-lgnum.
        IF NOT sy-subrc IS INITIAL.
      for plants without warehouses try to use the country code
          CASE mseg-werks.
            WHEN 'BUP'.
              t300-regkz := 'US '.
          ENDCASE.
        ENDIF.
        CLEAR mgef.
        SELECT SINGLE * FROM mgef WHERE stoff = mara-stoff
                                  AND   regkz = t300-regkz.
      ENDIF.
    in case of more then one label, use for each a new output window
    (not only for the first)
      IF g_count > 1.
        CALL FUNCTION 'CONTROL_FORM'
          EXPORTING
            command = 'NEW-WINDOW'.
      ENDIF.
    Ausgabe Gefahrstoffsysmbole        Neustadt,  V.Hilgert  14.07.98
    *For output type YNL7, the hazardous warning symbol has to be printed at  the bottom of the label.So label is called before that.
      IF tnapr-kschl = 'YNL7'.
        CALL FUNCTION 'WRITE_FORM'
          EXPORTING
            element = 'LABEL'.
      ENDIF.
      count_haz_sym = 0. position = 0.
      WHILE count_haz_sym  = 'XN'.
    For output type YNL7, the width of the standard text is small.
          IF tnapr-kschl = 'YNL7'.
            zw = position * '0.2' + '0.1'. pos = zw.
          ELSE.
            zw = position * '1.3' + '0.1'. pos = zw.
          ENDIF.
          IF tsp03d-patype = 'YZZX_ZEB'. " device type for ZEBRA label priter
            aux_value := count_haz_sym.
          ELSE.
            aux_value := pos.              " HP/Kyocera or other laser printer
          ENDIF.
          CALL FUNCTION 'TEXT_SYMBOL_SETVALUE'
            EXPORTING
              name   = '&XPOS&'
              value  = aux_value
            EXCEPTIONS
              OTHERS = 1.
          CALL FUNCTION 'WRITE_FORM'
            EXPORTING
              element   =
              window    = 'MAIN'
            EXCEPTIONS
              element   = 1
              function  = 2
              type      = 3
              unopened  = 4
              unstarted = 5
              window    = 6
              OTHERS    = 7.
          IF sy-subrc = 0.
    *Varying the position for YNL7
            IF tnapr-kschl = 'YNL7'.
              position = position + 2.
            ELSE.
              position = position + 1.
            ENDIF.
          ENDIF.
        ENDIF.
      ENDWHILE.
      IF NOT mseg-vfdat IS INITIAL.
        am07m-mhtxt = text-105.
      ENDIF.
      IF NOT am07m-mhdat IS INITIAL.
        am07m-mhztx = text-106.
      ENDIF.
      IF ekko-bsart = 'UB'.
        am07m-litxt = text-101.
        am07m-libzg = ekko-reswk.
      ELSE.
        am07m-litxt = text-100.
        am07m-libzg = ekko-lifnr.
      ENDIF.
      belpos-mblnr = mkpf-mblnr.
      belpos-zeile = mseg-zeile.
      CONDENSE belpos NO-GAPS.
      am07m-belpos = belpos.
      IF t156-shkzg = h.
        am07m-hdlne = text-020.
      ELSE.
        am07m-hdlne = text-010.
      ENDIF.
    Ausgabe der Etiketten mit den ind. Mengen
      IF NOT g_flag_popup IS INITIAL.
        SELECT SINGLE * FROM yzzm_gr_quantity WHERE ebeln = mseg-ebeln
                                              AND   weanz = g_count.
      ELSE.
    * print the number of labels is handeled by the Zebra printer
    IF tsp03d-patype = 'YZZX_ZEB'. " device type for Zebra label prts
    g_lbls_tot := mseg-weanz - g_count + 1.
    g_break_print := x.
    ENDIF.
    ENDIF.
    mseg-erfmg := yzzm_gr_quantity-erfmg.*
    ********26.09.2007 Starts
    CONCATENATE mseg-mblnr mseg-mjahr mseg-zeile INTO l_objky.
    SELECT SINGLE vstat INTO l_vstat FROM nast WHERE kappl = 'ME' AND
    objky = l_objky AND
    kschl = 'YNL7'.
    ********26.09.2007 Ends
    CALL FUNCTION 'TEXT_SYMBOL_SETVALUE'
    EXPORTING
    name = '&nummer&'
    value = g_count.
    IF tnapr-kschl <> 'YNL7'.
    CALL FUNCTION 'WRITE_FORM'
    EXPORTING
    element = 'LABEL'.
    else.
    CALL FUNCTION 'WRITE_FORM'
    EXPORTING
    ELEMENT = 'BAR_CODE'
    EXCEPTIONS
    ELEMENT = 1
    FUNCTION = 2
    TYPE = 3
    UNOPENED = 4
    UNSTARTED = 5
    WINDOW = 6
    BAD_PAGEFORMAT_FOR_PRINT = 7
    SPOOL_ERROR = 8
    CODEPAGE = 9
    OTHERS = 10.
    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.
    ENDFORM.                    "GR_label_print
    *&      Form  lesen
          text
         -->OBJKY      text
    FORM lesen USING objky.
      nast_key = objky.
      CLEAR retco.
      SELECT SINGLE * FROM mkpf WHERE mblnr = nast_key-mblnr
                                AND   mjahr = nast_key-mjahr.
      SELECT SINGLE * FROM mseg WHERE mblnr = mkpf-mblnr
                                AND   zeile = nast_key-zeile
                                AND   mjahr = mkpf-mjahr.
      IF sy-subrc NE 0.
        retco = sy-subrc.
        EXIT.
      ENDIF.
      PERFORM tab156_lesen.
      xskkz = t156-rstyp.
      PERFORM tab001w_lesen.
      IF NOT mseg-evers IS INITIAL.         "Versandvorschriften lesen.
        PERFORM t027_lesen.
      ENDIF.
      PERFORM bestellung_lesen.
      IF NOT ekpo-knttp IS INITIAL AND NOT
             ekpo-weunb IS INITIAL.
        PERFORM kontierung_lesen.           "für multikontierte Bestellungen
      ENDIF.
      IF NOT mseg-ematn IS INITIAL.
        PERFORM lesen_htn.
      ELSE.                                                     "111277/PH
        CLEAR am07m-mfrpn.                                      "111277/PH
      ENDIF.
      IF mseg-matnr IS INITIAL.
        mseg-menge = mseg-bpmng.
        mseg-meins = mseg-bprme.
        PERFORM bestelltext_lesen.
        CLEAR mabdr.
      ELSE.
        PERFORM material_lesen.
      ENDIF.
      PERFORM tab024_lesen.
      PERFORM t064b_lesen.
      PERFORM ladr_lesen.
    ENDFORM.                    "lesen
    Lesen für WE-Schein Fert.Auftrag -
    FORM lesen_wf USING objky.
      nast_key = objky.
      CLEAR retco.
      SELECT SINGLE * FROM mkpf WHERE mblnr = nast_key-mblnr
                                AND   mjahr = nast_key-mjahr.
      SELECT SINGLE * FROM mseg WHERE mblnr = mkpf-mblnr
                                AND   zeile = nast_key-zeile
                                AND   mjahr = mkpf-mjahr.
      IF sy-subrc NE 0.
        retco = sy-subrc.
        EXIT.
      ENDIF.
      PERFORM tab156_lesen.
      xskkz = t156-rstyp.
      PERFORM tab001w_lesen.
      PERFORM auftrag_lesen.
      IF NOT mseg-matnr IS INITIAL.
        PERFORM material_lesen.
      ELSE.
        mseg-menge = mseg-erfmg.
        mseg-meins = mseg-erfme.
      ENDIF.
      PERFORM tab024d_lesen.
      PERFORM t064b_lesen.
      PERFORM ladr_lesen.
    ENDFORM.                    "lesen_wf
    Lesen für Warenausgang -
    FORM lesen_wa USING objky.
      nast_key = objky.
      CLEAR retco.
      SELECT SINGLE * FROM mkpf WHERE mblnr = nast_key-mblnr
                                AND   mjahr = nast_key-mjahr.
      SELECT SINGLE * FROM mseg WHERE mblnr = mkpf-mblnr
                                AND   zeile = nast_key-zeile
                                AND   mjahr = mkpf-mjahr.
      IF sy-subrc NE 0.
        retco = sy-subrc.
        EXIT.
      ENDIF.
      PERFORM tab156_lesen.
      xskkz = t156-rstyp.
      PERFORM tab001w_lesen.
      IF NOT mseg-matnr IS INITIAL.
        PERFORM material_lesen.
      ENDIF.
      PERFORM ladr_lesen.
    ENDFORM.                    "lesen_wa
    Druck Vorbereiten -
    FORM open_form.
      PERFORM itcpo_fuellen.
      CALL FUNCTION 'OPEN_FORM'
        EXPORTING
          device   = 'PRINTER'
          language = language
          OPTIONS  = itcpo
          dialog   = ' '.
      PERFORM lesen_t159p.
      x_open = x.
    ENDFORM.                    "open_form
    Druck Vorbereiten Sammelscheine -
    FORM open_form_sammel.
      PERFORM lesen_t159p.
      PERFORM itcpo_fuellen.
      CALL FUNCTION 'OPEN_FORM'
        EXPORTING
          device   = 'PRINTER'
          language = language
          OPTIONS  = itcpo
          form     = tnapr-fonam
          dialog   = ' '.
      x_open = x.
    ENDFORM.                    "open_form_sammel
    Druck schließen -
    FORM close_form.
      CHECK NOT x_open IS INITIAL.
      CALL FUNCTION 'CLOSE_FORM'.
      CLEAR x_open.
    ENDFORM.                    "close_form
    Hilfsfelder versorgen für Sammelscheindruck -
    FORM helpdata1.
       *mkpf = mkpf.
       *mseg-lgort = mseg-lgort.
       *ladr = ladr.
      save_mkpf = *mkpf-usnam.
      save_mblnr = *mkpf-mblnr.
      save_budat = *mkpf-budat.
      save_cpudt = *mkpf-cpudt.
      save_ematn = *mseg-ematn.
      save_lgort = *mseg-lgort.
      save_ladr = *ladr.
       *t001w = t001w.
      save_werks = *t001w-werks.
      save_name1 = *t001w-name1.
       *ekko = ekko.
       *am07m = am07m.
      save_lifnr = *ekko-lifnr.
      save_ebeln = *ekko-ebeln.
      save_ekgrp = *ekko-ekgrp.
      save_linam = *am07m-name1.
      save_lina2 = *am07m-name2.
       *t024 = t024.
      save_eknam = *t024-eknam.
      save_ektel = *t024-ektel.
       *mkpf-usnam = old_mkpf.
       *mkpf-mblnr = old_mblnr.
       *mkpf-cpudt = old_cpudt.
       *mkpf-budat = old_budat.
       *mseg-ematn = old_ematn.
       *mseg-lgort = old_lgort.
       *ladr = old_ladr.
       *t001w-werks = old_werks.
       *t001w-name1 = old_name1.
       *t024-eknam = old_eknam.
       *t024-ektel = old_ektel.
       *ekko-lifnr = old_lifnr.
       *ekko-ebeln = old_ebeln.
       *ekko-ekgrp = old_ekgrp.
       *am07m-name1 = old_linam.
       *am07m-name2 = old_lina2.
      save_lfa1  = lfa1.
      IF NOT old_lfa1 IS INITIAL.
        lfa1  = old_lfa1.
      ENDIF.
    ENDFORM.                                                    "helpdata1
    --- Versorgung der Hilfsfelder vor CLOSE_FORM bei Sammelscheindruck --
    FORM helpdata2.
      old_lfa1 = save_lfa1.
      lfa1     = save_lfa1.
      old_mkpf = save_mkpf.
      old_lgort = save_lgort.
      old_ladr = save_ladr.
      old_budat = save_budat.
      old_cpudt = save_cpudt.
      old_werks = save_werks.
      old_name1 = save_name1.
      old_mblnr = save_mblnr.
      old_lifnr = save_lifnr.
      old_linam = save_linam.
      old_lina2 = save_lina2.
      old_ebeln = save_ebeln.
      old_ekgrp = save_ekgrp.
      old_eknam = save_eknam.
      old_ektel = save_ektel.
      old_ematn = save_ematn.
       *mkpf-usnam = save_mkpf.
       *mkpf-mblnr = save_mblnr.
       *mkpf-budat = save_budat.
       *mkpf-cpudt = save_cpudt.
       *mseg-ematn = save_ematn.
       *mseg-lgort = save_lgort.
       *ladr = save_ladr.
       *t001w-werks = save_werks.
       *t001w-name1 = save_name1.
       *t024-eknam  = save_eknam.
       *t024-ektel  = save_ektel.
       *ekko-lifnr  = save_lifnr.
       *ekko-ebeln  = save_ebeln.
       *ekko-ekgrp  = save_ekgrp.
       *am07m-name1 = save_linam.
       *am07m-name2 = save_lina2.
    ENDFORM.                                                    "helpdata2
    Form Lesen Warenausgang Lohnbearbeiter -
    FORM lesen_wlb USING objky.
      nast_key = objky.
      CLEAR retco.
      SELECT SINGLE * FROM mkpf WHERE mblnr = nast_key-mblnr
                                AND   mjahr = nast_key-mjahr.
      SELECT SINGLE * FROM mseg WHERE mblnr = mkpf-mblnr
                                AND   zeile = nast_key-zeile
                                AND   mjahr = mkpf-mjahr.
      IF sy-subrc NE 0.
        retco = sy-subrc.
        EXIT.
      ENDIF.
      PERFORM tab156_lesen.
      xskkz = t156-rstyp.
      PERFORM tab001w_lesen.
      IF NOT mseg-matnr IS INITIAL.
        PERFORM material_lesen.
      ENDIF.
      ON CHANGE OF mseg-lifnr.
        PERFORM read_address.
      ENDON.
    ENDFORM.                    "lesen_wlb
    *eject
    Fuellen der ITCPO -
    FORM itcpo_fuellen.
      IF xscreen NE space.
    *- Testausgabe auf Bildschirm -
        itcpo-tdpreview = 'X'.
        itcpo-tdnoprint = 'X'.
      ELSE.
        CLEAR: itcpo-tdpreview,
               itcpo-tdnoprint.
      ENDIF.
      MOVE-CORRESPONDING nast TO itcpo.
      itcpo-tdcover   = nast-tdocover.
      itcpo-tddest    = nast-ldest.
      itcpo-tddataset = nast-dsnam.
      itcpo-tdsuffix1 = nast-dsuf1.
      itcpo-tdsuffix2 = nast-dsuf2.
      itcpo-tdimmed   = nast-dimme.
      itcpo-tddelete  = nast-delet.
      itcpo-tdcopies  = nast-anzal.
      itcpo-tdprogram = sy-repid.
    ITCPO-TDTELELAND = US_COUNTRY.
      itcpo-tdsenddate = nast-vsdat.
      itcpo-tdsendtime = nast-vsura.
      itcpo-tdnewid   = x.
    ENDFORM.                    "itcpo_fuellen
    *eject.
    ------------ FORM lesen der Lagerortadr. ---------------------------*
    FORM ladr_lesen.
      DATA:    BEGIN OF addr_sel.
              INCLUDE STRUCTURE addr1_sel.
      DATA:    END OF addr_sel.
      CLEAR ladr.
      SELECT SINGLE * FROM twlad WHERE werks = mseg-werks
                           AND  lgort = mseg-lgort
                           AND  lfdnr = '001'.
      IF NOT twlad-adrnr IS INITIAL AND sy-subrc IS INITIAL.
        MOVE twlad-adrnr TO addr_sel-addrnumber.
      ENDIF.
      CALL FUNCTION 'ADDR_GET'
        EXPORTING
          address_selection = addr_sel
        IMPORTING
          sadr              = ladr
        EXCEPTIONS
          OTHERS            = 1.
    ENDFORM.                    "ladr_lesen
    **&      Form  REPRINT
          text
    *FORM reprint.
    TABLES : nase.
    DATA  : x TYPE string.
    IF nase-vermo = 2.
       x = 'REPRINT'.
    ENDIF.
    *ENDFORM.                    "REPRINT
    Kindly do the needful.
    Thanks in advance
    Regards
    Swarna

    Hi Swarna,
    CALL FUNCTION 'OPEN_FORM'
    EXPORTING
    device = 'PRINTER'
    language = language
    OPTIONS = print_infos
    <b>form = tnapr-fonam</b>
    dialog = ' '.
    x_open := x.
    I thing its not a good way to pass the Form name to the Parameter.
    Try like,
    data : temp_form like tnapr-fonam.
    <b>form = temp_form</b>
    Thanks.

  • How to print sapscript coding?

    Hi friends,
    How to print sapscript like form details, attributes and text elements? This is for documentation purposes.
    rozie

    Hi rozie,
    Go through this url it is given step by step process.
    APScripts
    http://esnips.com/doc/1ff9f8e8-0a4c-42a7-8819-6e3ff9e7ab44/sapscripts.pdf
    http://esnips.com/doc/1e487f0c-8009-4ae1-9f9c-c07bd953dbfa/script-command.pdf
    http://esnips.com/doc/64d4eccb-e09b-48e1-9be9-e2818d73f074/faqss.pdf
    http://esnips.com/doc/cb7e39b4-3161-437f-bfc6-21e6a50e1b39/sscript.pdf
    http://esnips.com/doc/fced4d36-ba52-4df9-ab35-b3d194830bbf/symbols-in-scripts.pdf
    http://esnips.com/doc/b57e8989-ccf0-40d0-8992-8183be831030/sapscript-how-to-calculate-totals-and-subtotals.htm
    SAP SCRIPT FIELDS
    http://help.sap.com/saphelp_erp2005vp/helpdata/en/d1/8033ea454211d189710000e8322d00/content.htm
    scripts easy material
    http://www.allsaplinks.com/sap_script_made_easy.html
    Debugging Document.
    http://www.cba.nau.edu/haney-j/CIS497/Assignments/Debugging.doc
    http://help.sap.com/saphelp_47x200/helpdata/en/c6/617ca9e68c11d2b2ab080009b43351/content.htm
    http://www.cba.nau.edu/haney-j/CIS497/Assignments/Debugging.doc
    http://help.sap.com/saphelp_erp2005/helpdata/en/b3/d322540c3beb4ba53795784eebb680/frameset.htm
    http://help.sap.com/saphelp_nw04/helpdata/en/84/1f624f4505144199e3d570cf7a9225/frameset.htm
    http://help.sap.com/saphelp_bw30b/helpdata/en/c6/617ca9e68c11d2b2ab080009b43351/content.htm
    http://help.sap.com/saphelp_erp2005/helpdata/en/b3/d322540c3beb4ba53795784eebb680/frameset.htm
    Rewards some points if it is helpful.
    Rgds,
    P.Nag

  • Printing SAPSCRIPT FORM vai RFC---URGENT

    Hi All
    I have a requirement where i am calling a Function moule (  present in destinataion system ) via RFC , from the source system.
    Inside the Function module , i have requirement to call/submit a print program for a script form (Considering that the Form and Print program are in destination system).
    Doing this, is there a way to have the SAPSCRIPT output ( ie a Spool) captured or copied in the source system?
    Any pointers on the above would be of great help.
    Thanks
    Pankaj

    Dear all,
    I think I've got the answer (even though it is 3 years after question was posted).
    Let me re-cap the problem:
    1) A set of SAPscript form and print program (beginning with 'Z') for physical inventory document are developed
    2) This set of SAPscript form and print program produce similar printout as that in T-code: MI03, or MI01 or MI02
    3) The SAPscript form is copied from "INVENT" or "INVENT_VKBW" and the print program is copied from "RM07IDRU" or "RWWVINVB"
    4) However, there is no output types available for configuration for user to print physical inventory document using this new set of SAPscript form and print program
    Am I correct ?
    The re-solution is:  Maintain the output types entries (program, form) in table "T159N"
    1) T-code: MI01 , MI02, MI04 will call T-code: MI21 when user selects to print physical inventory document
    2) T-code: MI21 will call print program "RM07IDRU" (this is maintained in T-code SE93)
    3) Program RM07IDRU" will call SAPscript "INVENT" or "INVENT_VKBW" (this is maintained in table "T159N")
    Hence, if you develop new sets of SAPscript form and print program (by copying from "INVENT" or "INVENT_VKBW" / "RM07IDRU" or "RWWVINVB"), try table "T159N".
    Simon

  • Send mail/fax/print SAPSCRIPT

    Hi Experts,
    I need to modify SAPSCRIPT in transaction F.64.
    This Layout I need to send as Email/fax/print as per user requirement.
    Could give me sample code tht i need to modify in Print program to achieve the above functionality///.............
    Its Urgent.........Answers will be rewarded...

    Hi,
    For mail attachemnt:
    REPORT Z_SCRIPT .
    DATA: itcpo LIKE itcpo,
    tab_lines LIKE sy-tabix.
    Variables for EMAIL functionality
    DATA: maildata LIKE sodocchgi1.
    DATA: mailpack LIKE sopcklsti1 OCCURS 2 WITH HEADER LINE.
    DATA: mailhead LIKE solisti1 OCCURS 1 WITH HEADER LINE.
    DATA: mailbin LIKE solisti1 OCCURS 10 WITH HEADER LINE.
    DATA: mailtxt LIKE solisti1 OCCURS 10 WITH HEADER LINE.
    DATA: mailrec LIKE somlrec90 OCCURS 0 WITH HEADER LINE.
    DATA: solisti1 LIKE solisti1 OCCURS 0 WITH HEADER LINE.
    *PERFORM send_form_via_email.
    FORM SEND_FORM_VIA_EMAIL *
    FORM send_form_via_email.
    CLEAR: maildata, mailtxt, mailbin, mailpack, mailhead, mailrec.
    REFRESH: mailtxt, mailbin, mailpack, mailhead, mailrec.
    Creation of the document to be sent File Name
    maildata-obj_name = 'TEST'.
    Mail Subject
    maildata-obj_descr = 'Subject'.
    Mail Contents
    mailtxt-line = 'Here is your file'.
    APPEND mailtxt.
    Prepare Packing List
    PERFORM prepare_packing_list.
    Set recipient - email address here!!!
    mailrec-receiver = 'email.COM'.
    mailrec-rec_type = 'U'.
    APPEND mailrec.
    Sending the document
    CALL FUNCTION 'SO_NEW_DOCUMENT_ATT_SEND_API1'
    EXPORTING
    document_data = maildata
    put_in_outbox = ' '
    TABLES
    packing_list = mailpack
    object_header = mailhead
    contents_bin = mailbin
    contents_txt = mailtxt
    receivers = mailrec
    EXCEPTIONS
    too_many_receivers = 1
    document_not_sent = 2
    operation_no_authorization = 4
    OTHERS = 99.
    ENDFORM.
    Form PREPARE_PACKING_LIST
    FORM prepare_packing_list.
    CLEAR: mailpack, mailbin, mailhead.
    REFRESH: mailpack, mailbin, mailhead.
    DESCRIBE TABLE mailtxt LINES tab_lines.
    READ TABLE mailtxt INDEX tab_lines.
    maildata-doc_size = ( tab_lines - 1 ) * 255 + STRLEN( mailtxt ).
    Creation of the entry for the compressed document
    CLEAR mailpack-transf_bin.
    mailpack-head_start = 1.
    mailpack-head_num = 0.
    mailpack-body_start = 1.
    mailpack-body_num = tab_lines.
    mailpack-doc_type = 'RAW'.
    APPEND mailpack.
    Creation of the document attachment
    This form gets the OTF code from the SAPscript form.
    If you already have your OTF code, I believe that you may
    be able to skip this form. just do the following code, looping thru
    your SOLISTI1 and updating MAILBIN.
    PERFORM get_otf_code.
    LOOP AT solisti1.
    MOVE-CORRESPONDING solisti1 TO mailbin.
    APPEND mailbin.
    ENDLOOP.
    DESCRIBE TABLE mailbin LINES tab_lines.
    mailhead = 'TEST.OTF'.
    APPEND mailhead.
    Creation of the entry for the compressed attachment
    mailpack-transf_bin = 'X'.
    mailpack-head_start = 1.
    mailpack-head_num = 1.
    mailpack-body_start = 1.
    mailpack-body_num = tab_lines.
    mailpack-doc_type = 'OTF'.
    mailpack-obj_name = 'TEST'.
    mailpack-obj_descr = 'Subject'.
    mailpack-doc_size = tab_lines * 255.
    APPEND mailpack.
    ENDFORM.
    Form GET_OTF_CODE
    FORM get_otf_code.
    DATA: BEGIN OF otf OCCURS 0.
    INCLUDE STRUCTURE itcoo .
    DATA: END OF otf.
    DATA: itcpo LIKE itcpo.
    DATA: itcpp LIKE itcpp.
    CLEAR itcpo.
    itcpo-tdgetotf = 'X'.
    Start writing OTF code
    CALL FUNCTION 'OPEN_FORM'
    EXPORTING
    form = 'Z08V3_COLLI'
    language = sy-langu
    options = itcpo
    dialog = ' '
    EXCEPTIONS
    OTHERS = 1.
    CALL FUNCTION 'START_FORM'
    EXCEPTIONS
    error_message = 01
    OTHERS = 02.
    CALL FUNCTION 'WRITE_FORM'
    EXPORTING
    window = 'MAIN'
    EXCEPTIONS
    error_message = 01
    OTHERS = 02.
    Close up Form and get OTF code
    CALL FUNCTION 'END_FORM'
    EXCEPTIONS
    error_message = 01
    OTHERS = 02.
    MOVE-CORRESPONDING itcpo TO itcpp.
    CALL FUNCTION 'CLOSE_FORM'
    IMPORTING
    result = itcpp
    TABLES
    otfdata = otf
    EXCEPTIONS
    OTHERS = 1.
    Move OTF code to structure SOLI form email
    CLEAR solisti1. REFRESH solisti1.
    LOOP AT otf.
    solisti1-line = otf.
    APPEND solisti1.
    ENDLOOP.
    ENDFORM
    For FAx Attaxhment:
    REPORT RSKSENDF MESSAGE-ID SK.
    Test report to send a test fax
    sends a fax to the number <TO_CNTRY>-<TO_NMBER>
    containing an automatically generated message text.
    TABLES: USR03.
    PARAMETERS: TO_CNTRY LIKE T005-LAND1 OBLIGATORY,
    TO_NMBER LIKE TSP01-RQTELENUM OBLIGATORY,
    FROM_USR(30) TYPE C DEFAULT SY-UNAME,
    TO_RECIP(30) TYPE C DEFAULT SY-UNAME.
    SAPscript content ITAB
    DATA: BEGIN OF TEST_DOC OCCURS 10.
    INCLUDE STRUCTURE TLINE.
    DATA: END OF TEST_DOC.
    SAPscript header struct
    DATA BEGIN OF HEADER.
    INCLUDE STRUCTURE THEAD.
    DATA END OF HEADER.
    INITIALIZATION.
    get county from user addres in usr03
    system->user profile->user address
    check if not empty
    SELECT SINGLE * FROM USR03 WHERE BNAME = SY-UNAME.
    IF SY-SUBRC = 0 AND USR03-LAND1 <> SPACE.
    TO_CNTRY = USR03-LAND1.
    ENDIF.
    START-OF-SELECTION.
    PERFORM FILL_UP_TEST_DOC.
    PERFORM SHOW_TEST_DOC.
    AT PF08.
    PERFORM SEND_FAX TABLES TEST_DOC USING TO_CNTRY
    TO_NMBER.
    AT SELECTION-SCREEN ON TO_NMBER.
    PERFORM CHECK_NUMBER USING TO_CNTRY TO_NMBER.
    *& Form CHECK_NUMBER
    FORM CHECK_NUMBER USING
    COUNTRY
    NUMBER.
    DATA: SERVICE LIKE TSKPA-SERVICE VALUE 'TELEFAX',
    LEN LIKE SY-FDPOS.
    FIELD-SYMBOLS <P>.
    windows GUI push the ? from mandatory input instead
    of overwriting it
    LEN = STRLEN( TO_NMBER ).
    IF LEN > 1.
    SUBTRACT 1 FROM LEN.
    ASSIGN TO_NMBER+LEN(1) TO <P>.
    IF <P> = '?'.
    <P> = SPACE.
    ENDIF.
    ENDIF.
    official check FM
    CALL FUNCTION 'TELECOMMUNICATION_NUMBER_CHECK'
    EXPORTING
    COUNTRY = COUNTRY
    NUMBER = NUMBER
    SERVICE = SERVICE.
    on old 21?/22? release you may have to handle the
    exception
    because the Function uses RAISE instead of
    MESSAGE... RAISING....
    ENDFORM. " CHECK_NUMBER
    *& Form FILL_UP_TEST_DOC
    fills test text in itab TEST_DOC *
    real life example needs to get real life data *
    FORM FILL_UP_TEST_DOC.
    DATA: DATUM(12) TYPE C,
    UZEIT(10) TYPE C.
    SAPscript initialization
    of course, you may want to set a few parameter
    (FORM,LAYOUT,....)
    CALL FUNCTION 'INIT_TEXT'
    EXPORTING
    ID = 'ST '
    LANGUAGE = SY-LANGU
    NAME = 'FOO-BAR'
    OBJECT = 'TEXT'
    IMPORTING
    HEADER = HEADER
    TABLES
    LINES = TEST_DOC
    EXCEPTIONS
    OTHERS = 1.
    IF SY-SUBRC <> 0.
    MESSAGE A400 WITH 'INIT_TEXT'.
    ENDIF.
    PERFORM ADD_EMPTY_LINE.
    WRITE: SY-DATUM TO DATUM.
    WRITE: SY-UZEIT TO UZEIT.
    PERFORM ADD_LINES USING 'This is test Telefax'(001)
    DATUM UZEIT.
    PERFORM ADD_EMPTY_LINE.
    PERFORM ADD_LINES USING 'From: &'(002) FROM_USR SPACE.
    PERFORM ADD_LINES USING 'To: &'(003) TO_RECIP SPACE.
    PERFORM ADD_LINES USING 'Fax number: & &'(004)
    TO_CNTRY TO_NMBER.
    PERFORM ADD_EMPTY_LINE.
    PERFORM ADD_LINES USING
    'This is a test fax send by Report RSKSENDF'(005)
    SPACE SPACE.
    PERFORM ADD_LINES USING 'on SAP system & '(006)
    SY-SYSID SPACE.
    PERFORM ADD_EMPTY_LINE.
    PERFORM ADD_LINES USING
    'the quick brown fox jumps over the lazy dog.'(101)
    SPACE SAPCE.
    PERFORM ADD_LINES USING
    'THE QUICK BROWN FOX JUMPS OVER THE LAZY DOG.'(102)
    SPACE SAPCE.
    PERFORM ADD_EMPTY_LINE.
    PERFORM ADD_LINES USING 'End of test'(007) SPACE
    SPACE.
    ENDFORM. " FILL_UP_TEST_DOC
    *& Form ADD_LINES
    printf a line an appends it in test_doc *
    --> cformat format.
    --> p1 param1
    --> p2 param2
    FORM ADD_LINES USING CFORMAT P1 P2.
    TEST_DOC-TDFORMAT = '/'.
    TEST_DOC-TDLINE = CFORMAT.
    IF TEST_DOC-TDLINE CA '&'.
    REPLACE '&' WITH P1 INTO TEST_DOC-TDLINE.
    IF TEST_DOC-TDLINE CA '&'.
    REPLACE '&' WITH P2 INTO TEST_DOC-TDLINE.
    ENDIF.
    ENDIF.
    APPEND TEST_DOC.
    ENDFORM. " ADD_LINES
    *& Form ADD_EMPTY_LINE
    appends an empty line to test_doc *
    FORM ADD_EMPTY_LINE.
    TEST_DOC-TDFORMAT = '/'.
    CLEAR TEST_DOC-TDLINE.
    APPEND TEST_DOC.
    ENDFORM. " ADD_EMPTY_LINE
    *& Form SHOW_TEST_DOC
    lists the test doc for aproval *
    *>>>> this is for fun only because PRINT_TEXT also
    offers a preview *
    FORM SHOW_TEST_DOC.
    FORMAT COLOR COL_BACKGROUND INTENSIFIED OFF.
    WRITE: / 'Test fax would look like this:'(020).
    ULINE.
    SKIP.
    LOOP AT TEST_DOC.
    IF TEST_DOC-TDLINE <> SPACE.
    WRITE:/ TEST_DOC-TDLINE.
    ELSE.
    SKIP.
    ENDIF.
    ENDLOOP.
    SKIP.
    ULINE.
    FORMAT COLOR COL_POSITIVE INTENSIFIED OFF.
    WRITE: 'Press PF8 to send it'(021).
    ENDFORM. " SHOW_TEST_DOC
    *& Form SEND_FAX
    send fax by calling SAPscript *
    Note: Instead of using PRINT_TEXT you may also *
    call OPEN_FORM / WRITE_FORM_LINES / CLOSE_FORM, *
    this allows you to use a similar program structure *
    as with NEW-PAGE PRINT ON / WRITE / NEW-PAGE PRINT
    OFF *
    FORM SEND_FAX
    TABLES DOC2FAX STRUCTURE TEST_DOC
    USING COUNTRY
    NUMBER.
    DATA: SID(5) TYPE N.
    DATA BEGIN OF POPT.
    INCLUDE STRUCTURE ITCPO.
    DATA END OF POPT.
    DATA BEGIN OF PRES.
    INCLUDE STRUCTURE ITCPP.
    DATA END OF PRES.
    CLEAR POPT.
    POPT-TDCOPIES = 1. " one copy
    POPT-TDDEST = " done internaly by script,
    POPT-TDPRINTER = " do not fill !!!
    POPT-TDNEWID = 'X'. " do not reuse old spool request
    POPT-TDDATASET = 'TEST'(022). " fill as you want
    POPT-TDSUFFIX1 = 'FAX'(023). " fill as you want
    POPT-TDSUFFIX2 = SY-UNAME. " fill as you want
    POPT-TDIMMED = 'X'. " send now
    POPT-TDLIFETIME = 8. " keep 8 days in spool
    POPT-TDTELENUM = NUMBER. " number without country code
    POPT-TDTELELAND = COUNTRY. " country of recipient
    POPT-TDCOVER = 'test fax'(024).
    POPT-TDCOVTITLE = 'test fax'(024).
    POPT-TDIEXIT = 'X'.
    CALL FUNCTION 'PRINT_TEXT'
    EXPORTING
    APPLICATION = 'TX'
    ARCHIVE_INDEX = ' '
    ARCHIVE_PARAMS = ' '
    DEVICE = 'TELEFAX' "<<< here we say: fax it !
    DIALOG = 'X'
    HEADER = HEADER
    OPTIONS = POPT
    IMPORTING
    RESULT = PRES
    TABLES
    LINES = DOC2FAX
    EXCEPTIONS
    OTHERS = 01.
    do not bother with exception in sample code
    CANCELED = 01
    DEVICE = 02
    FORM = 03
    OPTIONS = 04
    UNCLOSED = 05
    UNKNOWN = 06
    FORMAT = 07
    TEXTFORMAT = 08
    EXTERNAL = 09.
    IF SY-SUBRC = 0.
    arriving here means we could send:
    SID = PRES-TDSPOOLID.
    IF SID > '00000'.
    MESSAGE S433 WITH SID.
    ENDIF.
    LEAVE .
    ELSE.
    do not bother with exception in sample code
    MESSAGE A400 WITH 'PRIN_TEXT'.
    ENDIF.
    ENDFORM. " SEND_FAX
    TESTING:
    You can check with the transactions SOST or SOSB to monitor the outputs sent out from SAP.
    Regards,
    Shiva Kumar

  • A question on different zebra printer dpi printing - sapscript

    Hello,
    We have an existing sapsript (with ZPL code) to print label via a zebra printer (300dpi). There is a requirement to print
    the same label on new device zebra QL 320 plus(wireless printer, 203 dpi).
    Please advise how to make use of the existing sapscript to print to the wireless device without creating another sapscript(with different dpi).
    existing 300dpi ZPL code in sapscript:
    ^FX
    ~DGR:ROHS.GRF,2222,22,jG0IFCI07LFCT07HFJ03HFJ07JFI07MFT03HFJ03HFJ0KF8H07MF8S03HFJ03HFI03KFEH07MFES03HFJ03HFI07LFH07NFS03HFJ03HFI0MF807NF8R03HFJ03HFI0MF807NFCR03HFJ03HFH01MFE07NFCR03HFJ03HFH03MFE07NFCR03HFJ03HFH03MFE07NFER03HFJ03HFH07NF07NFER03HFJ03HFH07HFC01IF07NFER03HFJ03HFH07HF801IF07FEI01IFR03HFJ03HFH07FEI07HF07FEJ0IFR03HFJ03HFH07FEI03HF87FEJ07HFR03HFJ03HFH07FEI03HF87FEJ07HFR03HFJ03HFH0HFCI01HF87FEJ07HF8I03HFEJ03HFJ03HFH0HFCI01HFC7FEJ03HF8I0JF8I03HFJ03HFH0HFCI01HFC7FEJ03HF8H01JFCI03HFJ03HFH0HFCJ0HFC7FEJ03HF8H03KFI03HFJ03HFH0HFCJ0HFC7FEJ03HF8H0LF8H03HFJ03HFH0HFEM07FEJ03HFI0LF8H03HFJ03HFH0HFEM07FEJ03HFH01LFEH03HFJ03HFH07HFM07FEJ07HFH03LFEH03HFJ03HFH07HFEL07FEJ07FEH07LFEH03OFH07IF8K07FEJ0HFEH07MFH03OFH07JF8J07FEI01HFEH0IFC1IFH03OFH07KF8I07FEI03HFEH0IFH07HF803OFH03KFEI07NFCH0HFEH03HF803OFH03LFCH07NFCH0HFEH03HFC03OFH01MFH07NFI0HFCH01HFC03OFI0MF807NFH01HFCI0HFC03OFI0MFE07MFEH01HF8I0HFC03OFI07MF07MFCH01HF8I0HFC03OFI01MF07NFH03HF8I0HFE03OFJ0MF87NFH03HFJ07FE03HFJ03HFJ01LFC7NF803HFJ07FE03HFJ03HFL0KFC7NFC03HFJ07FE03HFJ03HFL07JFC7NFC03HFJ07FE03HFJ03HFM07IFC7FEI0IFC03HFJ07FE03HFJ03HFM01IFE7FEI03HFE03HFJ07FE03HFJ03HFN03HFE7FEJ0HFE03HFJ07FE03HFJ03HFO0HFE7FEJ0HFE03HFJ07FE03HFJ03HFO0HFE7FEJ0HFE03HFJ07FE03HFJ03HF01H08J07FE7FEJ0HFE03HFJ07FE03HFJ03HF01HF8J07FE7FEJ07FE03HF8I0HFE03HFJ03HF01HF8J07FE7FEJ07FE03HF8I0HFC03HFJ03HF01HFCJ07FE7FEJ07FE01HF8I0HFC03HFJ03HF01HFCJ07FE7FEJ07FE01HFCI0HFC03HFJ03HF01HFEJ07FE7FEJ07FE01HFCH01HFC03HFJ03HFH0HFEJ0HFE7FEJ07FEH0HFCH03HFC03HFJ03HFH0HFEJ0HFC7FEJ07FEH0HFEH03HFC03HFJ03HFH0IFI01HFC7FEJ07FEH0IF807HF803HFJ03HFH07HFCH07HFC7FEJ07FEH07HFC1IFH03HFJ03HFH07IF01IFC7FEJ07FEH07MFH03HFJ03HFH07NFC7FEJ07FEH07MFH03HFJ03HFH03NF87FEJ07FEH03LFEH03HFJ03HFH03NF07FEJ07FEH01LFEH03HFJ03HFH01NF07FEJ07FEI0LF8H03HFJ03HFI0MFE07FEJ07FEI0LFI03HFJ03HFI07LFC07hHFE7gJFC7E3TFE7gJFC7E3TFE7gJFC7E3RF8FE7gJFC7E3RF8FE7gJFC7TF8FE7gJFC7TF8FE7gJFC7TF8FE7FC0IFC1JFC3FC3IFE1HFC7JF83JFC3HF8FE7FH03FEH03FE3H0FH0HF3803FC7E3FCH03FC6H0FC01E7CH01FCI0FE4H04H07F2H01FC7E3F8H01FC4H03C01E787F1FC7F0FE0FC0FC3F07F0FC7E3F8FE1FC1FC3F8FE78HF8F0HFC7E1FE1FE3F0HF8FC7E3F1HF8FC3FE3F8FE70HF8F0HFC7E1FE1FE1F0HFC7C7E3E1HF8FC3FE1F8FE71HFCF1HFC7E3FE1FE1F1HFC7C7E3JF8FC3HF1F8FE61IFE1HFE3E3FE3FE1F1HFC7C7E3JF0FC3HF1F8FE61IFE3HFE3E3FE3FE1F1HFC7C7E3HF8H0FC7HF1F8FE61IFE3HFE3E3FE3FE1F3HFC7C7E3FCI0FC7HF1F8FE61IFE3HFE3E3FE3FE1F3HFC7C7E3F01F8FC7HF1F8FE61IFE3HFE3E3FE3FE1F3HFC7C7E3E0HF8FC7HF1F8FE61IFE1HFE3E3FE3FE1F1HFC7C7E3E3HF8FC7HF1F8FE61HF8F1HFC7E3FE3FE1F1HFC7C7E3E3HF8FC7HF1F8FE71HF8F0HFC7E3FE3FE1F0HF87C7E3E3HF0FC7HF1F8FE70HF8F0HFC7E3FE3FE1F0HF8FC7E3E3FE0FC7HF1F8FE787E1FC7F0FE3FE3FE1F07F0FC7E3E1FC0FC7HF1F8FE7CH01FCI0FE3FE3FE1FI01FC7E3EI083C7HF1F81E7EH07FEH03FE3FE3FE1F1H07FC7E3F80383C7HF1FC1E7FH0IF807FE3FE3FE1F1807FC7E3F807C3C7HF1FC1E7YF1gHFE7YF1gHFE7YF1gHFE7YF1gHFE7YF1gHFEhJ07YF1gHFE7hHFE7hHFE7hHFE7hHFE
    ^XA
    ^PRC
    ^LH0,0^FS
    ^LL610
    ^MD0
    ^MMT
    ^MNY
    ^LH0,0^FS
    ^FO32,20^A0N,45,45^CI13^FR^FDPART #: 60000001^FS
    ^BY2,3.0^FO36,66^BCN,56,N,Y,N^FR^FD>:60000002^FS20000001
    ^FO709,74^A0N,45,45^CI13^FR^FDMSD: 60000003^FS20000002
    ^FO32,137^A0N,36,36^CI13^FR^FD60000004^FS
    ^FO32,183^A0N,36,36^CI13^FR^FDMPN: 60000005^FS30000001
    ^BY2,3.0^FO36,222^BCN,56,N,N,N,A^FR^FD60000006^FS
    ^FO32,293^A0N,36,36^CI13^FR^FDBATCH NO:  60000007^FS
    ^BY2,3.0^FO36,330^BCN,56,N,Y,N^FR^FD>:60000008^FS3000000230000003
    ^FO460,293^A0N,36,36^CI13^FR^FDD/CODE: 60000009^FS
    ^BY2,3.0^FO461,330^BCN,56,N,Y,N^FR^FD>:60000010^FS30000004
    ^BY42,42^FO750,300^BXN,5,200,0,0,1^FH\^FD60000011^FS30000005
    ^FO200,517^A0N,36,36^CI13^FR^FDCOO: 60000012 ^FS
    ^BY2,3.0^FO36,500^BCN,56,N,Y,N^FR^FD>:60000013^FS
    ^FO500,460^A0N,36,36^CI13^FR^FDQTY: 60000014^FS
    ^BY2,3.0^FO500,500^BCN,56,N,Y,N^FR^FD>:60000015^FS
    ^FO32,399^A0N,36,36^CI13^FR^FDSAP  Doc: 60000016^FS20000003
    ^FO500,399^A0N,36,36^CI13^FR^FDV/CODE: 60000017^FS20000004
    ^BY2,3.0^FO36,432^BCN,56,N,Y,N^FR^FD>:60000018^FS
    ^FO30,566^ABN,25,15^CI0^FR^FDDate RECEIVED: 60000019 ^FS
    ^FO520,566^ABN,25,15^CI13^FR^FDUser:60000020^FS20000005
    ^FO713,455^FR^XGRoHs,1,1^FS20000006
    ^FO0,282^GB931,0,2^FS
    ^FO0,126^GB931,0,2^FS
    ^FO0,172^GB931,0,2^FS
    ^FO0,390^GB931,0,2^FS
    ^FO0,558^GB931,0,2^FS
    ^XZ
    ^FX End of job
    ^FX END OF FORMAT

    Hi,
    You should generate a new label file and upload it to a new sapscript form as described in note #179534.
    Regards,
    Aidan

  • Problem with printing sapscript on new HP P2015 printers ?

    A brand new printer is installed the HP P2015 at a customer. suddenly all sapscripts are printed in courier. we have already updated the drivers but somehow it doesn't seem to work ?
    Is there something else that needs to be changed on the SAP side or just don't buy HP again perhaps the sollution ?

    >
    A. de Smidt wrote:
    > the driver ZHHP2015 from http://h71028.www7.hp.com/enterprise/cache/37011-0-0-225-121.html
    >
    > is installed. only it's still not working.
    > It became worse except for the title which is in lucida sans EF. but everything that is helvetica is printed through, so a whole sentence is compressed into 4 cm width over each other
    >
    > with the HPLJ5 driver the font at least was translated to a scalable courier kind of font
    hello Smidt , where you find that driver ( ZHHP2015 ) i dont see it in the link you post ? if you can it can you ema1l me it please ?
    ealmonte at e-diesco dot com
    thanks

  • Certificate of Origin with multiple line items in sapscript - Urgent Please

    Hi Everyone,
    Can you please help me with this issue in SAPSCRIPT.
    This is for billing document with multiple items with each line item with different country of origin.Right now the form is printing only one country of origin even if it has 3 line items each with different country.It's getting first line item's country and printing......but it should diplay each country with comma separated... But in debug it is showing all 3 different countries but in print it is printing only first country of origin.
       I have given text element as &VBDKR-TEXT& in form.
    In ABAP program I am getting country of origin like this,
    CLEAR : V_T005,VBRP , MARC  .
      LOOP AT TVBDPR.
      SELECT SINGLE * FROM VBRP
        WHERE VBELN = VBDKR-VBELN AND POSNR = TVBDPR-POSNR .
    begin of addiiton for ppr 13661
      CLEAR MCH1.
    SELECT SINGLE HERKL FROM MCH1 INTO MCH1-HERKL WHERE MATNR = VBRP-MATNR
                                           AND CHARG = VBdpR-CHARG.
      IF MCH1-HERKL NE ' '.
        CLEAR MARC-HERKL.
        MARC-HERKL = MCH1-HERKL.
      ELSE.
        NAME = VBDKR-VBELN.
          PERFORM HEADER_TEXT1 USING 'VBBK' 'Z065' NAME SY-LANGU.
        IF SY-SUBRC EQ 0.
          READ TABLE TEXT_LINES INDEX 1 .
          IF SY-SUBRC EQ 0.
            VBDKR-TEXT = TEXT_LINES-TDLINE.
          ENDIF.
        ELSE.
          SELECT SINGLE * FROM MARC WHERE MATNR = VBRP-MATNR
                                    AND   WERKS = VBRP-WERKS.
        ENDIF.                                                  "ppr 13661
      ENDIF.                               "PPR 13661 ADD
      CLEAR *T005T.
    data:SEP(3) VALUE ' , '.
    DATA: BEGIN OF ITAB OCCURS 100,
           LANDX LIKE VBDKR-TEXT,
          END OF ITAB.
    clear ITAB.
      SELECT  LANDX FROM T005T INTO table itab WHERE SPRAS = SY-LANGU  AND
    LAND1 = MARC-HERKL.
    LOOP AT itab.
    VBDKR-TEXT = ITAB-LANDX.
    *MOVE VBDKR-TEXT TO ZLAND.
    AT NEW LANDX.
       concatenate ITAB-LANDX sep into VBDKR-TEXT.
    ENDAT.
    modify ITAB.
    VBDKR-TEXT = ITAB-LANDX.
    ENDLOOP.
    endloop.
    Thanks in advance.

    Hi
    It depends on the size of the main in the page, you can set the high of main in order to print max a certain number of rows (so items).
    In this way you don't need the abap control, but the system automatically will print the first page with 15 row and the next with 25

  • Check Printing SAPSCRIPT

    Check Printing
    Posted: Sep 2, 2005 1:34 AM        Reply      E-mail this post 
    Hi All,
    I am working on check printing in SAPSCRIPT. I am modifying the standard program RFFOUS_C. Can anyone give me the the technical flow of this standard program.
    regards,
    Bala

    If no body answer you the first time, maybe nobody will answer you the second time.
    Please stop repost same question ...

  • Problems when printing Sapscript...

    We have imported a number Sapscripts in Russian into our unicode system. Looking at the Sapscript I can see Russian text in both the first and next page of the form. However, when printing the first page looks perfect and displays in Russian, however, the second page shows hashes (#) where the Russian text should be.
    If none of it worked I might be able to understand what was going on, but when the first page prints fine I find it difficult to understand what is going on.
    I have run a check agianst both pages in SE71 and re-activated, but still no joy. What could be going wrong?.
    Gary

    Thanks guys, I have now found out what the problem was.
    All my test data was set up for me by the functional guys. The output messages that were repeated were originally set  to language of English rather than Russian, and hence the problem.
    Apologies everyone.
    Regards
    Gary King

  • Printing SAPScripts in Thai on Hp Printers

    Dear Experts,
    I am trying to set up Thai printing in my system. I created a output device with device type, THSAPWIN. In the print preview of SAPScripts, my thai characters are cramped together in a mess and when I tried to print, I just see "#" everywhere.
    Please help...
    Thanks,
    KH

    The logic to build SAP Script and Smart form of all languages will be same. But while working on Asian language please take care of the following points.
    1 Make sure you logon to SAP in thai language only.
    2 At the Operating system level install the thai language.[Control panel - >Regional and language Option - >language Tab - > Click on Install Files for East Asian languages] If these language already installed then click on Detail and add the thai languages
    3 At SAP level click on Customizing of Local layout[Alt+F12] and click on options.Go to tab I18N and click on Activate the multi-byte functionalities to support check box.
    4.Take care of the Font while assigning to Character formar or paragraph format. Dont use normal font name. Example of chinese phone "CNSONG

  • Problem with printing report (URGENT)

    hi every body, (urgent)
    When I print a report the margin of report not as i am like, i change the setting of printer to be suitable with what i want but nothong change,so the output of report not good.
    can any body tell me if can change margin of the printer from inside the report (at run time) or any solution.
    thanks
    null

    its the simple student management system where the teacher will input the marks of the students in particular subjects and store it in the database. now i have to print that on the report card. printing report as per student might be troublesome so i want to implement the " print all" button where the report card of all the students in that class will be printed in the report cards. its: printer printing the report of a student in the paper (A4 size) and then printer takes another paper sheet and then print the report of another student of same class until finish. how to accomplish this task?

  • Printing SAPscript for Prenumbered Bill of Exchange under RFFOUS_C

    Hi collegues,
    We are developping a sapscript to create a prenumbered bill of exchange that is to be printed with advice, all in the same page.
    We have use sapscript F110_EN_CHECK to make copy ZF110_CHECK but we are not managing to print it correctly under RFFOUS_C, because it doesn't cover BOE's but checks... but our problem is that RFFO__D doesn't seem to manage prenumbered forms.
    Which changes should be done on RFFOUS_C and F110_EN_CHECK to get both things: prenumbered BOE and advice.
    Or maybe, we are not facing this issue in the most suitable way and there are other choices we should take into account?
    Thanks in advance.
    Rushid

    We have finally managed to print a prenumbered BOE. We have created ZRFFOUS_C report as a copy of RFFOUS_C and ZRFFORI02 include as a copy of RFFORI02 - BOE and assigne it to ZRFFOUS_C after RFFORI01 include.
    On include ZRFFORI02 we have changed the entries for text element '555' to be '545' and 'MAIN' window to be 'CHECK'.
    Afterwards. we have included on window CHECK on sapscript ZF110_BOE (copy of F110_ES_CHEQUE) three elemts: WEFIW(2) WEFIW4 and WEFAE6.
    Now we are able to print prenumbered BOE.
    i hope this will help someone in a future.

  • DD PRINT-SAPSCRIPT

    Hi ,
       I had done DD Print in SAPSCRIPT by using Print program RFFOUS_C.
       When this DD Print is done in F110 transaction(Automatic Payment Run)  it is
       expected to print more than one DD.But in my case one DD is printing properly
       and the next DD is not getting printed properly and also for printing the second DD , the printer head goes to half of the DD(Pre-printed Statinary) .Help me to solve this issue.
    Thanks.

    hi
    in the <b>SPAD> click on Full Administaration button in application toolbar>select DEvice typetab>again click DEVICE TYPE button>select the devicetype ur using then click on FORMAT button on the application tool bar...it will display the list of format</b> using by the printer.
    based on this may be the printer roll the paper... check whether there is an entry related to your DD size... i hope it helps you..
    Message was edited by:
            Naresh Reddy

  • Printing Report - Urgent please

    Hi All,
    Can anyone please help me with the following printing problem.
    I created a report using class cl_gui_list_tree. The report looks like our windows directory stucture. Like directory/sub-directory/file. This is NOT sapscript.
    The above class does not have any print methods. I used the following code to print it. It shows the print parameter screen where we can select the printer/format etc. Once press the green check mark, it will not do anything.
    The code:
    case ok_code.
      when 'PRIN'.
      data: l_status type c.
      call function 'PRINT_REPORT'
        exporting
         NO_DIALOG                    = ' '
          report                       = sy-repid
       IMPORTING
         STATUS                       = l_status
       EXCEPTIONS
         ARCHIVE_INFO_NOT_FOUND       = 1
         OTHERS                       = 2
      if sy-subrc <> 0.
      endif.
    First question is: Can I use the above function module for printing?
    If this is not the right one please let me know the right function module.
    If we can use above function module whatelse I have to do to get it printed?
    Thanks in advance.

    I am not sure for the function module but here is a suggestion - write data to spool, get the spool request no.
    And then use fm RSPO_OUTPUT_SPOOL_REQUEST to print spool request.
    You can try this approach. Let me know if you need any help to create Spool request.

Maybe you are looking for

  • HP Photosmart D110a - Scanner no longer works after upgrading to OS Mavericks 10.9

    I have an iMac. I upgraded my system to OS 10.9.5 Mavericks and the scanner of my multifunctional HP Photosmart D110a stopped working. Images imported by the scanner can not be saved in any format. I tried importing and saving from many different app

  • Work Center CR02

    Hi,     We have created Work Center in 2007 with the following Validity date Jan 2007 to Dec 2009. I have checked the Validity date of associated Cost Center and its ending Year is 9999. Now I want to Change the Validity date of Work Center to 9999.

  • Default text in the body of mail when sent to vendor thru PO

    Dear friends, We need to put in the email body a message to vendor. We wrote in the tcode NACE a message in the text field and the email was generated , but without the text body ! The attachment has been generated correctly. but no text in the body

  • S10e (4187XB5) wireless fails after a few seconds

    The wireless thinks it is connected. It connects to the home (or office) wireless without trouble, acquires valid IP address, etc., but behaves as if unconnected after a few seconds. I have tried: Uninstalling and reinstalling the network adapter via

  • Add element or property to XML header (from property set)

    I would like to add an element or property to an outbound XML message. I saw references to Tech Note 304, but I can no longer find it. Can anyone remember what was in Tech Note 304, or knows how I can do this?