Table content alignment in SAP Scripts

000010       MAG DX 17P           7,000                   PC     1.520,00       10.640,00
000020       mag pa/dx  175             6,000             PX     1.599,00       9.594,00
000030       MVC MULTI SYNC XV15      5,000      PC     2.301,00       10.155,00
000040       MVC MULTI SYNC XV   17   1,000      PC     2.389,00        2.389,00       
The above is the output i got...
table i hv used is VBAP
POSEX  -  6
ARKTX  -  40
KWMENG  - 15
MEINS - 3
NETPR - 11
ZWERT - 13
TABS i hv specified in paragraph format is 1,7,47,62,65,76,89....
i hv compressed the kwmeng,netpr,zwert field as it has leading zeros....
How to arrange the table contents in proper order?
how to wrap the ARKTX field contents as it is too long for certain vbeln values...i think its the reason y im nt getin o/p in proper format......
Is there any mapping need to be done for CURRENCY & QUANTITY fields as we do in smartforms....if so pls provide needful help...

If i try these tab values am getting it as such.....
000010 MAG DX 17P  7,000                                 PC                           1.520,00  
10.640,00
000020 mag pa/dx    175 6,000                            PX                           1.599,00
9.594,00
000030 MVC MULTI SYNC XV15     5,000           PC                            2.301,00
10.155,00
000040 MVC MULTI SYNC XV 17      1,000         PC                            2.389,00
2.389,00
i think the problem is with the field "item decription"- ARKTX.......
In smartforms there is a tab to map with currency and quantity fields ,is there anything as such in sap scripts?

Similar Messages

  • Drawing Table & Displaying Data in SAP Script : Data Alignment probelm

    Hi Experts,
    I am Developing An SAP Script in Which Had to Display Data in a Table with Three column & multiple rows, i had created the Table using BOX Command in SAP SCRIPT & assigned a TEXT Element to it & calling this text element while Looping in WRITE_FORM FM.but while displaying DATA in One column the data in another columns shift to the right & if the data in 1st column is less the data in the second column shift to the left. i know these issues had been covered in the past but i am not getting any concrete results from searching in the forum.
    Also On more problem when ever i am declaring a text element in some other window & also giving the Command BOX inside it to draw outline the BOX is not drawn.
    This seem to be an alignment issue . Experts Please provide me with some alternative.
    Thanks & Regards
    Priyesh Shah

    Hi ,
    To stop columns going left and right.Use number of position in the variable .Like fix the lenght &name(10)&.Here name can print 10 characters.
    For box not appearing in other window check the box command parameters .It will draw.Not a alignment problum.

  • Issue with the font and alignment in SAP Script PDF

    Hi Experts,
    I have a problem with the font in SAP Script PDF conversion.
    The output of the form is working fine but in the PDF the output is wrong.
    There is a dutch letter ' ï ' which is pinted in the form output correctly but in the PDF output the character
    has been changed to '#'.
    and also the alignment of some text has beed changed without line spacing in between.
    Please let me know what could be the problem and how to solve this issue.
    Thanks in advance,
    Regards,
    Sankara Chakradhar.

    Hi Prabhudas,
    I am using the FM 'CONVERT_OTF' to convert the data to pdf.
    The FM CLOSE_FORM is creating the IT_OTF internal table and the CONVERT_PDF uses that internal table to populate the         IT_PDF internal table and then using the FM 'SO_OBJECT_SEND' to send the PDF file to mail.
      CALL FUNCTION 'CONVERT_OTF'             
           EXPORTING                          
                format       = 'PDF'          
           IMPORTING                          
                bin_filesize = g_filesize     
           TABLES                             
                otf          = it_otf         
                lines        = it_pdf.        
    Regards,
    Sankara Chakradhar.

  • Read RFC output table contents using com.sap.mw.jco.* API

    Hi,
    I have a requirement where I need to call an RFC in JSPDynpage component.
    In doInitialization method, I wrote following code: -
    IPortalComponentRequest request = (IPortalComponentRequest) this.getRequest();
    IPortalComponentContext myContext = request.getComponentContext();
    IPortalComponentProfile myProfile = myContext.getProfile();
    String sapSystem = myProfile.getProperty("SystemIdentifier");
    ISystemLandscapeWrapper landscapeWrapper = (ISystemLandscapeWrapper) UMFactory.getSystemLandscapeWrappers().get(0);
    ISystemLandscapeObject systemLandscapeObject = landscapeWrapper.getSystemByAlias(sapSystem);
    IJCOClientService clientService = (IJCOClientService) PortalRuntime.getRuntimeResources().getService(JCO_CLIENT);
    request.getNode().putValue(LOCALE_NODE_KEY,     Locale.ENGLISH);
    IJCOClientPoolEntry poolEntry = clientService.getJCOClientPoolEntry(sapSystem,request);
    JCO.Client client = poolEntry.getJCOClient();
    client.connect();
    IRepository repository = JCO.createRepository("repository", client);
    IFunctionTemplate functionTemplate = repository.getFunctionTemplate(Z_BAPI_EMP_GBU_GET);
    JCO.Function function = new JCO.Function(functionTemplate);
    JCO.ParameterList importList = function.getImportParameterList();
    importList.setValue("US", "OBJTYP");
    importList.setValue(request.getUser().getUniqueName(), "USRID");
    client.execute(function);
    Now, this RFC returns two tables.
    I want to know how do I read a table and iterate over its contents to read all fields.
    (Till now, I only used getString("GBU") method that just reads an export type of String parameter)
    Please help.
    Thanks & Regards,
    Amey

    Amey,
    If I understood the problem correctly. A snippet will be something like
                   JCO.Table itemList = function.getTableParameterList().getTable("QUALIFICATION");
                   Vector qualItems = new Vector();
                   QualItemBean qualItem;
                   for (int i = 0; i < itemList.getNumRows(); i++) {
                        itemList.setRow(i);
                        qualItem = new QualItemBean();
                        qualItem.setQual(itemList.getString("TBJID").trim());
                        qualItem.setQualText(itemList.getString("TTEXT").trim());
                        qualItem.setVBDate(itemList.getString("VBEGD").trim());
                        qualItem.setSBDate(itemList.getString("SBEGD").trim());
                        qualItem.setSEDate(itemList.getString("SENDD").trim());
                        qualItem.setVEDate(itemList.getString("VENDD").trim());
                        qualItem.setProfText(itemList.getString("PROFC_TEXT").trim());
                        qualItems.add(qualItem);
                   qualBean.setQual(qualItems);
    Ofcourse you need to change the variable names based on your scenario.
    Thanks
    Prashant

  • Problem in creating 800 client to see table content .

    HI,
        I am new to sap .  I have ideas 4.7 in windows 2003.  i can see table content under user sap* and password 060719* . I  have created a user sapuser . through client 000 , i can create create abap program , but could not find ant table content like mara . at first time  after creating sapuser , it asked me the access key. i gave 36687663221261278694 and it has taken . but to see table content , i created a new user as partha in client 800. but at first time at the time of logging it is asking the access key. though i am giving same key it is not taking .
       1) is there any other key for that educational version ?
       2) how to crreate a user in client 800 . pls give step by step procedure .
       3) for creating a user under client 800 . should i delete my sapuser created under 000 client.

    Hi Jack,
    First of all, the client 000 is one of the standard clients that comes with any SAP R/3 installation (with client 001 and 066 (for EarlyWatch for SAP auditory purposes)). To work with the system you should always make a copy of the client 000 or 001 to a new client i.e. client 200, 400, or whatever name.
    In the case of IDES, the system always comes with the client 800, where you can find all the IDES configuration and data (for test, training, sandbox). If you want to work in the system you should work on this client (800). To check the tables you can always use transaction se12 (table structure: fields, keys) and se16 to see the table content. If you want to create users you should always do it in the client 800 or any other client you've created (not in the standard ones 000, 001, 066, try to maintain these clients clean of any custom data).
    To view the tables data you dont need any key.  The keys are requested when you want to register a developer user (to create a new abap program (all the new programs must start with Z (or X,Y) to differentiate from the standard SAP programs. The keys are also requested when you want to edit a standard program or table or any other standard SAP object.
    1) To get the keys for any SAP system (there are 2 types of keys: developer user and for editing any standard object) you must log on the OSS service (with the user and password provided by SAP when you got your SAP software) : service.sap.com/sscr. Here you use the installation number of your IDES system (the system must be registered in OSS) and then you can create your developer users or standard object keys.
    2)To create a user in any system you need to go to transaction SU01. Here you can make a copy of SAP* user for example (choosing in the trx the button copy) to create your new user. you assign a password to the user and save it. You need to login again on the system and put your new password. This is the easiest way, otherwise you can create a user from zero but you will need to add more information to the user. To start you can create a copy of SAP* or DDIC users.
    3) Yes, I suggest you delete the user you've created in client 000, try to keep it clean of any customer modifications (you could leave it there but is not a good practice).If you want to work with your IDES system and the IDES data, use the client 800.
    Good luck,

  • Issue in alignment of PE51 data when printing it in SAP Script

    Hi Experts
    I have a SAP Script which is used to print Check at the top and Re-numeration Statement at the second half via RFFOUS_C program. The re-numeration statement is designed in PE51. The Check is designed in SAP Script and the PE51 form is printing inside the script using Main window/ Text Element : 525-HR.
    The FM RP_IMPORT_PAY_STATEMENT is used inside the RFFOUS_C program which returns the table PFORM and the contents of  the PFORM is exactly the re-numeration statement data and are getting  printed one by one in the script using the variable REGUD-TXTHR. My object is fine with all the above said things. Only issue is with the alignment which is weird in SAP Script for the re-numeration part. But when I look into PC00_M10_CEDT (TCODE to view re-numeration statement) the output of designed PE51 form is good with proper alignment.When it is printed via script the alignment is not good at all.
    There is some differences in the formats of printing between PE51 and SE71. Do not know what exactly it is. How I can resolve this issue?
    Thanks
    Siva
    Message:Siva

    Hi Madhu,
    Sorry for the delayed response.See the below screen shot.This is how it prints now.The amounts are not aligned.Increasing the line spacing will increase only the space between the lines and i am using same character format for the variable REGUD-TXTHR.I would like to align them.
    Thanks
    Siva

  • Sap script '' how to create table frame in sap script"""

    i have some problem in sap script''  how to create table frame in sap script"""

    Hi,
    you can use BOX command..
    Syntax
    /: BOX [XPOS] [YPOS] [WIDTH] [HEIGHT] [FRAME] [INTENSITY]
    Effect: draws a box of the specified size at the specified position.
    Parameters: For each of XPOS, YPOS, WIDTH, HEIGHT and FRAME both a measurement and a unit of measurement must be specified. The INTENSITY parameter should be specified as a percentage between 0 and 100.
    1. XPOS, YPOS: Upper left corner of the box, relative to the values of the POSITION command.
    Default: Values specified in the POSITION command.
    The following calculation is performed internally to determine the absolute output position of a box on the page:
    X(abs) = XORIGIN + XPOS
    Y(abs) = YORIGIN + YPOS
    2. WIDTH: Width of the box. Default: WIDTH value of the SIZE command.
    3. HEIGHT: Height of the box. Default: HEIGHT value of the SIZE command.
    4. FRAME: Thickness of frame.
    Default: 0 (no frame).
    5. INTENSITY: Grayscale of box contents as % .
    Default: 100 (full black)
    Measurements: Decimal numbers must be specified as literal values (like ABAP numeric constants) by being enclosed in inverted commas. The period should be used as the decimal point character. See also the examples listed below.
    Units of measurement: The following units of measurement may be used:
    • TW (twip)
    • PT (point)
    • IN (inch)
    • MM (millimeter)
    • CM (centimeter)
    • LN (line)
    • CH (character).
    The following conversion factors apply:
    • 1 TW = 1/20 PT
    • 1 PT = 1/72 IN
    • 1 IN = 2.54 CM
    • 1 CM = 10 MM
    • 1 CH = height of a character relative to the CPI specification in the layout set header
    • 1 LN = height of a line relative to the LPI specification in the layout set header
    /: BOX FRAME 10 TW
    Draws a frame around the current window with a frame thickness of 10 TW (= 0.5 PT).
    /: BOX INTENSITY 10
    Fills the window background with shadowing having a gray scale of 10 %.
    /: BOX HEIGHT 0 TW FRAME 10 TW
    Draws a horizontal line across the complete top edge of the window.
    /: BOX WIDTH 0 TW FRAME 10 TW
    Draws a vertical line along the complete height of the left hand edge of the window.
    /: BOX WIDTH '17.5' CM HEIGHT 1 CM FRAME 10 TW INTENSITY 15
    /: BOX WIDTH '17.5' CM HEIGHT '13.5' CM FRAME 10 TW
    /: BOX XPOS '10.0' CM WIDTH 0 TW HEIGHT '13.5' CM FRAME 10 TW
    /: BOX XPOS '13.5' CM WIDTH 0 TW HEIGHT '13.5' CM FRAME 10 TW
    Draws two rectangles and two lines to construct a table of three columns with a highlighted heading section.
    check the fallowing link also
    http://help.sap.com/saphelp_40b/helpdata/en/d1/803293454211d189710000e8322d00/content.htm
    Mark the points if u find it useful...
    Regards,
    Omkar.

  • Dispaly standard text in SAP SCRIPT which content saved using SAVE_TEXT FM

    I want to display one standard text content in SAP SCRIPT and want to store content of it during run time.
    For that, first I have created one standard text using SO10.Named the standard text as Z_TEST_WRITE. Initially it was empty.
    In my SAP SCRIPT, I try to display the content of the standard text using below given SAP SCRIPT code and report program. Although I am able to store text in Standard text
    Z_TEST_WRITE but in first display of the SCRIPT it is not displaying against the include command of SAP SCRIPT. But when I see the content of Z_TEST_WRITE through SO10 transaction, I can see the content with new text which was previously empty.
    Now if I do the same transaction newly (suppose second time), then text stored in standard text Z_TEST_WRITE is displaid against includes command of SAP SCRIPT.
    My print program is a SAP STANDARD which one can be changed.
    /:   DEFINE &NAME& = ''                                      
    /:   PERFORM TEST IN PROGRAM Z_SAVE_TEXT
    /:   CHANGING &NAME&                                         
    /:   ENDPERFORM                                              
      <B>&NAME&</>                                            
    /:   INCLUDE Z_TEST_WRITE OBJECT TEXT ID ST
    REPORT  Z_SAVE_TEXT.
    FORM TEST TABLES IN_PAR STRUCTURE ITCSY
    OUT_PAR STRUCTURE ITCSY.
      DATA IT_HEADER LIKE TLINE OCCURS 0 WITH HEADER LINE.
      DATA: LS_HEADER LIKE THEAD,
            LT_LINES  TYPE STANDARD TABLE OF TLINE WITH HEADER LINE.
      OUT_PAR-NAME  = 'NAME'.
      OUT_PAR-VALUE =  'Sample text for Test'.
      APPEND OUT_PAR.
    *-Populate Header Text details
      LS_HEADER-TDOBJECT  = 'TEXT'.
      LS_HEADER-TDNAME    = 'Z_TEST_WRITE'.
      LS_HEADER-TDID      = 'ST'.
      LS_HEADER-TDSPRAS   = SY-LANGU.
    *-Populate details of Text
      CONCATENATE 'Shipment No   :' 'RM Ship No' INTO LT_LINES-TDLINE
      SEPARATED BY SPACE.
      LT_LINES-TDFORMAT = '*'.
      APPEND LT_LINES.
      CONCATENATE 'Bill of Lading:' '1234567' INTO LT_LINES-TDLINE
      SEPARATED BY SPACE.
      APPEND LT_LINES.
    *-Save Text
      CALL FUNCTION 'SAVE_TEXT'
        EXPORTING
          CLIENT          = SY-MANDT
          HEADER          = LS_HEADER
          SAVEMODE_DIRECT = 'V'
        TABLES
          LINES           = LT_LINES
        EXCEPTIONS
          OTHERS          = 1.
      IF SY-SUBRC NE 0.
        EXIT.
      ENDIF.
    COMMIT WORK and WAIT.
    ENDFORM.                    "TEST

    Hi,
      If the text is getting displayed the second time, then this should be due to delay in saving the text.
    After your COMMIT WORK AND WAIT in your report program, just put a WAIT FOR 2 SECS and check again.
    Regards,
    Suganya

  • Regarding passing table array to sap scripts - urgent

    Hi Experts,
    I am calling an SAP Script form from a custom program. The code snippet is as follows:
    MOVE : 'ZFRM_EX_COM_INV' TO w_form.
    PERFORM open_form USING w_form.
    PERFORM write_form USING 'MAIN'     'HEADER'.
    PERFORM write_form USING 'MAIN'     'LINE_ITEM'.
    LOOP AT it_cond INTO wa_cond.
    <b>PERFORM write_form USING 'TOTAL' 'TOTAL_COND'.</b>
                   <i> " TOTAL is the page window and TOTAL_COND is the element.</i>
    ENDLOOP.
    PERFORM close_form.
    *&      Form  write_form
          text
         -->VAR1       text
    FORM write_form USING var1 var2.
      IF var2 IS INITIAL.
        CALL FUNCTION 'WRITE_FORM'
          EXPORTING
            window                   = var1
          EXCEPTIONS
            element                  = 1
            function                 = 2
            type                     = 3
            unopened                 = 4
            unstarted                = 5
            window                   = 6
            bad_pageformat_for_print = 7
            OTHERS                   = 8.
      ELSE.
        CALL FUNCTION 'WRITE_FORM'
          EXPORTING
            element                  = var2
            window                   = var1
          EXCEPTIONS
            element                  = 1
            function                 = 2
            type                     = 3
            unopened                 = 4
            unstarted                = 5
            window                   = 6
            bad_pageformat_for_print = 7
            OTHERS                   = 8.
      ENDIF.
    ENDFORM.                               " WRITE_FORM
    In the text that is in bold in teh code snippet, I am tring to pass the values one-by-one and print in the output.
    But only the last line item from that table is begining printed. The other lines are overwritten by the last line.
    How should I display all the lines in the internal table it_cond.
    Please help me...
    regards,
    arul jothi a.

    U are using a variable window to print the 'total_cond' text element..
    so whenever u call the write form   for a variable window .. it will get over written by the current contents.. I t wont append the contents to the form...
    Instead u use this text element in the MAIN window then onli u will get all the data..
    i hope this is the problem..
    reward if it helps u...
    sai ramesh

  • SAP script printout alignment issue

    Hi Experts,
    I have facing one Script Printout Alignment issue.
    SAP Script Form printing some Values in Table format.
    While debugging( in debug mode ), I am getting the correct Alignment ( Proper table format with values ).
    But in printout the Alignment( The vertical and horizontal lines are not printed properly ) is not correct.
    Thanks in Advance.

    HI Glen Anthony,
    I am not using any printer details.
    from the Spol (SP01) I am checking the print priview.
    Success in debug mode but not in Print.
    Please suggest.
    Thanks

  • SAP SCRIPT ALIGNMENT

    All,
    I am developing a form with SAP Script. In the header window  (it is a single window using the almost entire width of page format DINA4)i am using three character formats for printing heder lines ofr ex: helve 8, helve 10 Bold and Helve 14 bold. When i see the print preview the alignment is perfect. But when i print the page alignment of header window is distorted. Why is it so? There is some other form using different character formats developed in smart forms. Here print out is coming properly. is this the problem with SAP script. If so what is the work around for this?
    Rakesh

    Hi
    Certain FONTS were not supported by certain printers, hence you may be getting such problem
    see the following OSS notes
    OSSNote:960341
    Symptom
    In some device types (e.g HPLJ4, HPLJ5) you experience non-uniform character spacing in the PDF document after the PDF conversion of SAPscript or Smart Forms documents, using HELVE or TIMES fonts. You want to know the reason.
    Other terms
    CONVERT_OTF, SAPscript, Smart Forms
    Reason and Prerequisites
    The problem is not due to an error in the PDF converter but due to the fact, that the printer font, underlying the device type (e.g. Univers or CG Times in PCL-5 device types), is not available for the PDF converter and is either not available in Adobe Reader. The PDF converter has to try to simulate the layout of the printer font by means of a font which is predefined in Adobe Reader. This is done by assigning the letter widths of the printer font to the font used in Adobe Reader.
    The PDF file contains a table with letter widths, used by Adobe Reader in the output of text, for each used printer font (except PostScript fonts).
    Example:
    %Charwidth values from HP4300 HELVE 060 normal
    /Widths
    [ 278 333 500 633 633 1000 758 333 333 333 633...
    Adobe reader converts this width table, by modifying the space between each character, so that the specified letter width (= space between the current and the next letter) is kept.
    This 'Simulation' of printer fonts results in the sometimes visible irregular spaces in PDF.
    The PDF converter always uses the Helvetica Adobe PostScript font for the display of HELVE and the Times Roman Adobe PostScript font for the display of TIMES. However, for these Adobe PostScript fonts, Adobe Reader often uses a Windows TrueType font, which differs slightly from the original PostScript font.
    Solution
    Workaround: Use the POST2 PostScript device type or the PDF1 PDF device type for the PDF conversion of documents in the Latin-1 character set. They both use the Adobe PostScript fonts Helvetica or Times Roman for the HELVE/TIMES printer fonts.
    Header Data
    Release Status: Released for Customer
    Released on: 30.06.2006  12:44:06
    Priority: Recommendations/additional info
    Category: Consulting
    Primary Component: BC-CCM-PRN Print and Output Management
    Secondary Components: BC-SRV-SCR SAPscript
    OSS Note: 776507
    Symptom
    Documents printed via SAPscript or SmartForms do not print with correct special characters, e.g. ### prints instead of Japanese or Russian characters. What to do?
    Other terms
    SAPscript, SmartForms, printing, device types, OTF
    Reason and Prerequisites
    Help required to choose proper fonts in a SAPscript or SmartForm
    Solution
    When using SAPscript or SmartForms to print (or email or fax) a form from a business application, many factors influence the outcome of the actual text within the form. All these factors must be checked in order to ensure a correct printout:
    1) The language version of the form used to produce the printout.
    Example: If you want to print a French invoice, you need to have a FR version of your SAPscript or SmartForms invoice form RVINVOICE01. And the application program must specify the corresponding language key (FR) when calling the SAPscript or SmartForms API.
    2) The font selections specified in the form (possibly also in a SAPscript style or SmartStyle used in a form).
    Example: In a SAPscript form or a SmartStyle you need to specify HELVE if you want to print German text in Helvetica (or similar) font. If you want to print Japanese text, HELVE is not a valid choice but you need to specify a Japanese font like JPMINCHO in your Japanese form.
    3) The output character set of the device type
    Every printer in transaction SPAD has a "device type" assigned. Device types used by the spooler for printing support only one single specific output character set. All text from the form has to be converted (using SAP's built-in character conversion mechanism) to this output character set.
    A character set can typically support either a single language (e.g. Shift-JIS which supports only Japanese) or a set of languages (e.g. ISO 8859-1, which supports Western-European languages). It is possible that a given language (such as German) can be supported by several output character sets, e.g. you may use either ISO 8895-1 (Latin-1) or ISO 8859-2 (Latin-2) to represent German text. This is so because both character sets contain the special characters used in German.
    Example: HPLJ4000 is a HP LaserJet device type supporting the ISO 8859-1 (Latin-1) character set. ISO 8859-1 can be used to represent e.g. Dutch, English, French, German, Spanish, Swedish but NOT Russian or Japanese.
    As a consequence, it is ok to use HPLJ4000 to print English, German French etc. but not for Japanese or Russian.
    4) The set of available printer fonts for a given device type
    When formatting a document, SAPscript and SmartForms perform an automatic mapping of the font definitions in the form (e.g. "HELVE 14 point bold") and the available printer fonts of the device type. A replacement printer font is chosen, should the specified font selection not be available in the device type. Now this replacement can be problematic if a language-specific font, such as Chinese CNSONG, is specified in a form and it gets replaced by a font which does not support this language, e.g. COURIER.
    To solve this problem, font families in SE73 have language attribute assigned, e.g. some fonts are characterized as being suitable only for certain languages. And when a replacement has to be chosen because the original font from the form is not available in the device type, a replacement font is chosen which has the same language attributes.
    If no fonts for the language in question exist in the device type, the resulting font will not be able to print the special characters and you will see "wrong" output characters in the printout.
    Note on SAPscript/SmartForms Print Preview:
    The OTF Print Preview available in Windows GUI (e.g. from transaction SP01) will sometimes not show the "wrong" characters which appear on the final printout. Here is the reason: since the Print Preview runs in Windows environment, it will use Windows fonts to represent the actual printer fonts. A Windows font typically has more available characters (i.e. covers more character sets) than are actually available in a printer's resident font.
    A typical example where the Print Preview will differ from the printout is here: if you have a Chinese PCL5 printer such as CNHPLJ4 and use the Western Latin font COURIER in your document, the print preview will show you Chinese characters if you (by accident) tried to format Chinese characters in COURIER font. This is because Windows will automatically choose a font that can output Chinese characters (which is actually not Courier). But when you print the job on an actual PCL5 printer with resident Western and Chinese fonts, the Courier font will not print any Chinese characters but Western special characters instead, because the printer's resident Courier font does not include Chinese characters.
    Rule of thumb: all Asian device types (e.g. CNHPLJ4, JPHPLJ4, JPPOST, KPHPLJ4) support not only Asian fonts but also COURIER, HELVE and TIMES fonts. But these Latin fonts can only be used to print English text, not Chinese/Japanese/Korean characters.
    Which fonts are suitable for a given language?
    Language(s):            Font family to use in a form:
    Latin-1 (Western Europe/Americas) *******
    DE,EN,FR,ES,NL,SV       COURIER, HELVE, TIMES
                            (LETGOTH, LNPRINT)
    Latin-2 (Central Europe) ****************
    PL, CZ                  COURIER, HELVE, TIMES
    ISO 8859-4 (Baltic) *********************
    ET, LT, LV              COURIER, HELVE, TIMES
    ISO 8859-5 (Cyrillic) *******************
    BG, RU, SR, UK          COURCYR, HELVCYR, TIMECYR
    ISO 8859-7 (Greek) **********************
    EL                      COUR_I7, HELV_I7, TIME_I7
    ISO 8859-8 (Hebrew) *********************
    HE                      COURIER, HELVE, TIMES
    ISO 8859-9 (Turkish) ********************
    TR                      COURIER, HELVE, TIMES
    Simplified Chinese **********************
    ZH                      CNHEI, CNKAI, CNSONG
    Japanese ********************************
    JA                      JPMINCHO, DBMINCHO, DBGOTHIC
    Korean **********************************
    KP                      KPBATANG, KPDODUM, KPGULIM
                            KPGUNGSE, KPSAMMUL
    Traditional Chinese *********************
    ZF                      TWDPHEI, TWMING, TWSONG
    Thai ************************************
    TH                      THANGSAN, THDRAFT, THVIJIT
    Arabic (Unicode systems only) ***********
    AR                      ANDALE_J
    Verify your output by examining the OTF data
    When analysing printing problems of this type, be sure to check the OTF data which gets produced by SAPscript or SmartForms. OTF or "Output Text Format" is the intermediate page-description format generated from SAPscript or SmartForms. OTF will contain the final printer font names and character set/language identifiers which help to solve the problem. OTF will even name the form and the language of the form used to create the output.
    The easiest way to do this is to create a spool request from your application, run transaction SP01, use menu
    Goto->Display Requests->Settings
    and choose
    Display Mode: Raw
    Now display your spool request. If this is a SAPscript or SmartForms spool request, you will see OTF data. Each line represents one OTF command, every command starts with a 2-character cmd identifier and possibly some cmd parameters follow.
    Here is an excerpt from a sample OTF file where we highlight the most interesting commands:
    //XHPLJ8000    0700 00000000001
    IN04EALEXTEST_ZEBRA
    IN05%PAGE1
    OPDINA4  P 144  240 1683811906000010000100001
    IN06%WINDOW2
    MT0024401289
    CP11000000E
    FCHELVE  120  00109XSF100SF101110000067E X
    UL +0000000000000
    SW00067
    CT00000000
    ST0453037Dieses SF hat Stil ALEXTEST_ZEBRA mit
    The 1st line with the // (Control) command reveals the device type usedto print: HPLJ8000
    //XHPLJ8000    0700 00000000001
    The 2nd line (IN = Info command) shows the name and (internal 1-char)language key of the form:
    IN04EALEXTEST_ZEBRA
    In this case it is the English (E = EN) SmartForm ALEXTEST_ZEBRA
    The OP-line (OP = Open Page) gives the page format used in the form, it is DINA4 Portrait orientation:
    OPDINA4  P 144  240 1683811906000010000100001
    The CP (CodePage) cmd shows the SAP system codepage used to code the text and the active language. In our case it is codepage 1100 and language E = EN = English.
    CP11000000E
    Finally, the FC-cmd (Font Call) lists a printer font selected within SmartForms. Please note that every SmartForm has a designated default SmartStyle under "Form Attributes->Output Options". In addition, every text node can have a SmartStyle attached (which will override the definitions from the default style for the text). In our case the resulting printer font that was selected is HELVE 12.0 pt bold-off, italic-off.
    FCHELVE   120  00109XSF100SF101110000067E X
    Header Data
    Release Status: Released for Customer
    Released on: 22.08.2005  09:57:20
    Priority: Recommendations/additional info
    Category: Customizing
    Primary Component: BC-CCM-PRN Print and Output Management
    Secondary Components: BC-SRV-SCR SAPscript
    BC-SRV-SSF Smart Forms
    <b>Reward points for useful Answers</b>
    Regards
    Anji

  • SAP-Script - Draw Table (Boxes) with variable number of lines

    Hello,
    I want to create a Table with Frames in a SAP-Script Form. First of all I don´t know the position of the table in the window main. It can be page 2 or 3 on top or in the middle. But i have to describe a position like
    POSITION YORIGIN '12.95' CM.  How can i position the table in a variable way?
    And i don´t know the number of lines of the table. How can I manage to draw the correct numbers of boxes as numbers of lines exist?
    Kind Regards
    Carsten Fuchs

    Hi carsten,
    1. Drawing GRID (just like excel, matrix)
       is very cumbersome in sapscript layout.
      (either dynamically, or hardcoded)
    2. Moreover, the final look,
       may or maynot appear as requried,.
      ie. exactly with proper alignment and grid lines.
    3. If the font size is required to change,
      then the dynamic position also changes.
    4. If the grid is supposed to go to the next page,
      again the calculation and logic becomes tougher.
    5. To use grid, its better to use smartform,
       which provided FINE CONTROL of the grid
      and its lines and width, height, style etc.
    6. In sapsctip, at most we can use
       UNDERLINE (_) and PIPE (|)
    regards,
    amit m.

  • Table name where all the SAP Script names are stored

    Hi Gurus,
                   Can i know the table name where all the SAP Script names are stored in SAP Database.
                   Thanks in advance,
                    Shyam.

    Yes TNAPR is the table which contains sapscipts name and print program names.
    Step:1: Goto to the Table TNAPR using SE11
    Step:2: Get the Contents of the Table(CNTRLSHIFTF10)
    Step:3: On the Table Content Selection Screen, Type the driver program name in the field PGNAM and execute(F8).
    Step:4: FONAM field of the result display contains the SAPScript Name for our driver program.
    Regards,
    Lalit Mohan Gupta.

  • Alignment problem in SAp Script

    Hi All,
    I am quite new to ABAP. I was working in .net for two years. I am developing an
    SAP script which includes table layout. No my problem is that certain texts in certain columns is so longer that the alignment get distorted. Is there any way in sap script by which we can bring down the text to next line if the text length exceeds certain limit. In web development it is possible to display like that and i hope it is possible in sap script also. Could any one please help me?

    Hi,
    First you need to consider the of the maximum possible length of each program symbol you are giving in the table layout. Depending upon that you need to create Tab spaces in "Paragraph formats" option.
    Each tabspace will allocate certain length of space to each program symbol.
    Plz reward if helpful.
    Thanks,
    Nagendra

  • Internal table in sap script

    Hello All ,
    I  have got a internal table with tracking numbers and I want to print all the numbers in that internal table on sap script.
    Please advise.
    Thanks
    Moderator message:  please search for available information before asking.
    locked by: Thomas Zloch on Sep 13, 2010 1:09 PM

    Hi,
    You can create a sub-routine and pass all the table entries in variables and then you can print them.

Maybe you are looking for