Chinese Character Printing in Smartform (Different Question)

Hi all,
Can anyone explain to me further the OSS Note 776507 that Anji Reddy Vangala recently posted?  It involves the preview and printing of different character sets.  Currently I've managed to preview my form correctly, but it still prints out #'s.  Do I need to re-assign the fonts to the printer device or something, or do I need to use a different printer?  The printer I am currently using is an HP 2100.  Please please help, anyone?
<b>EDIT:</b> Probably a better question would be how to map the conversion font of CNSONG to something that can be read by the printer?
A copy of the note for everyone's reference:
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<b></b><b></b><b></b>

Hi,
there a different things to know.
I produce sapscript forms with cinese and english characters for frontend / backend and archiv printing.
Please check:
Editor displays ###: You have to install the chinese language in your e.g. windows-system to display them.
Script: You have to chose the the font family "CNSONG" (customized for chinese simplified and LATIN).
Transaction I18N: May you have to set correct subfonts for the unicode areas (Cascading fonts, Standard is Courier).
You can print in different ways:
For archiv/PDF: Install the unicode truetype font with chinese characters for the pdf-converter.
For Frontend: Use the Frontendprinter SAPWIN or SAPWIN*CF (Cascading Font) to send it to the gui (note: SAPLPD does not support it, use the newer technology.....)
Backend printing: POSTSCRIPT is not yet implemented :-((
PLease note: What you see in spool / print preview is a simulation of the possible print, but backend print is not frontend preview!!!!
Regards,
Christian

Similar Messages

  • Chinese characters print in smartforms

    hi,
    the print preview in smart form is displaying the Chinese characters as required but  while printing the Chinese character these characters
    are replaced by ####### .
    thanks,
    nag.

    Nr,
    its not an ABAP issue at all i already gone thru this situation once.i change the printer specification from SPAD under eye of basis guy so you may want to do same.
    don't worry its not an ABAP issue.
    Amit.

  • Printing chinese text in a smartform.

    Whenever, I try to write chinese text in the smrtform, some weird characters appear. How can I paste chinese text in the smartform. Please provide me a solution.
    Moderator message: please do some research before asking.
    [Rules of engagement|http://wiki.sdn.sap.com/wiki/display/HOME/RulesofEngagement]
    Edited by: Thomas Zloch on Feb 28, 2011 9:21 AM

    Please check with your basis that your output device support print Chinese character. Or, you can search more in forum, there are a lot of threads about print Chinese and other Unicode characters in form.
    Thanks,

  • Issue with character formats using duplex printing in smartform

    Hi all,
    I am getting a problem with character formats using duplex printing in smartform. I am using a text module with a bold character to display text in a window. The problem is that on the first back page,the text is being printed normally (without bold), but on the next pages, the back pages are being printed with the bold character format.
    Can anyone know where is the problem..please.
    Points to be rewarded..
    Thanks.
    Regards,
    Zaheed.

    Hi Zaheed,
    Normally this should not happen.. and also there is no internal formatting done by SAP.. it will show based on what fomatting option we have specified..
    If you are saying it is happening in ur case then
         1. Recheck whether whether you have same text module getting printed on the
             two page. If they are different then then individual check formatting option for
             each..
          2. If above point does'nt work for you ..then instead of bold char use normal
              format for text element and see if it is printing same on both page..
    Try this out and let us know your findings...
    Enjoy SAP.
    Pankaj Singh

  • Additional Problem with Smartform Chinese Character Output

    Hi all!
    This is a follow-up to my earlier question about output of Chinese Characters in Smartforms.
    As a recap, my problem is to correctly output Chinese characters in my Smartform using English logon.  Using the OSS Note: 776507 that Anji sent, I managed to output in my Smartform preview the Chinese characters.  However, when I print a hardcopy, I still get the # characters.
    I tried uploading the font that outputs the chinese characters on MS Office, specifically Arial Unicode MS.  It was automatically assigned to the printer driver (I think).
    Is there anything I am doing or did wrong? 
    Thanks in advance for the help.  Points for any useful answer.

    Hi Pat,
    I have installed the lastest version of Adobe Reader (10.0.1) and Adobe Reader Font Pack (Asian Font Pack) and the results are as below:
    tested that the file (.pdf) cannot be displayed correctly
    It is appreciate if you have any idea for the issue. Thanks.
    Just let you know that the simplified chinese characters may inserted by the software (Free PDF Reader and Writer - Nitro Reader 3.1.1.3).

  • Question about chinese character report

    Hi, I will print some report contain chinese character. My OS is RedHat Linux Advanced server & Application server is oracle 9ias 9.0.2.0.1
    I have already set NLS_LANG="SIMPLIFIED CHINESE_CHINA.ZHS16GBK" in reports.sh. And have add
    helvetica = "ARIALUNI.TTF"(ARIALUNI.TTF is in my reports_path )
    in uifont.ali file under [ PDF:Subset ] section.
    But I still can not see chinese character in my report(PDF), How to solve it ?
    thanks .

    Rao , Thanks for your reply.
    After I Changed locale to chinese in Linux, I can not seen chinese in Oracle Enterprise manager. So, I think my lunux box can not support Chinese .
    When I run my report on windows2000 (Chinese version) application server, I can not see chinese character. But after I edit the uifont.ali and copy ARIALUNI.TTF to $reports_path, I can see chinese character.
    Do you get my means?
    Any question, Contact me.
    Thank you very much !

  • Cannot print out chinese character

    Hi All,
    I have problem with the printer. I can printed Chinese character without using SAP and from SAP when I print the Chinese character is not come out. On the paper will appear symbol ###. I don't how want to do.
    FYI, my system is Unicode.
    Thank You
    Regards,
    anang78

    Hi,
    Check the OSS note 776507 which talks about print preview for
    characters in Chinese language and print of ## characters during printing Asian languages.
    Please go through the note , as per section " Note on SAPscript/SmartForms Print Preview "
    we need to use device type CNHPLJ4 for printing Chinese character set.
    Thanks
    Jibin

  • Printing units with different decimals separator "in column"/ smartforms

    Hi.
    I want to print in SMARTFROMS different amounts under each other and the amounts are having different decimals places (depending on unit) - the printing should be, that the decimal separator is "in a column" and the units are in a "column"
    E.g.
    123,23 meters
    10,00   meters
    12,567 kg
    67 PCE
    should be printed as:
    123,23__meters
    10,00_meters
    12,567kg
    67____PCE
    How can I do this?
    Thanks a lot in advance

    Hi,
    Use a paragraph with tabstops. Define your tabs with align with decimal character.
    That defining can be done in smartstyles.  (tabstops are not alone in sapscript but also in smartforms)
    Gr., Frank

  • Report cant print Chinese character properly when direct output to printer

    I have follow the instruction {How to Print PDF/UTF8 in R12? [ID 778970.1]} {PASTA 3.0 Release Information}
    I am able to print the chinese character properly in PDF format. (direct to printer)
    However, some standard report like "Final Payment Register" "TEXT format" NOT able to print chinese character(direct to printer)
    When I preview the report it can display chinese character properly.
    Please advise

    However, some standard report like "Final Payment Register" "TEXT format" NOT able to print chinese character(direct to printer)
    When I preview the report it can display chinese character properly.Please see (What Happened To The Preliminary And Final Payment Register In R12? [ID 746339.1]).
    Thanks,
    Hussein

  • Cannot print Chinese character in postscript 11iAS

    We are using HRMS 11.5.10AS.
    We want to print the report in postscript. However, some chinese character cannot be print correctly. ( it's right in TXT )
    Anyone know how to solve it?

    chulongjiang,
    i solve the problem with your advice, thanks lot!
    Regards,
    Alan 24/11/2005

  • Printing a smartform to a different printer than my default

    I have a function module that gets passes a delivery number and the short-name of a printer.  The function module is supposed to print a smartform (pick list) for that delivery to the specified printer.  The problem is that no matter what I put in for the printer, it prints to my default printer.  If I change it, it will go there.  I'm sure I'm just missing some kind of setting.  Here is what I got:
    printer is the shortname for the printer i want, type RSPOPTYPE
    *Print Smartfomr picklist for  delivery
      data: ls_ctrl_prnt type ssfctrlop,
            ls_outp_opts type ssfcompop.
      ls_ctrl_prnt-no_dialog = 'X'.        " Suppres dialog
      ls_ctrl_prnt-device    = 'PRINTER'.
      ls_outp_opts-tddest    = printer.
      ls_outp_opts-tdprinter = printer.    " Specify required printer
      call function gv_func
        exporting
          control_parameters = ls_ctrl_prnt
          output_options = ls_outp_opts
          pk_hdr               = sf_info
          pk_orders            = sf_odrs
          pk_items             = sf_item
          pk_pgbk              = sf_pgbk
        exceptions
          formatting_error   = 1
          internal_error     = 2
          send_error         = 3
          user_canceled      = 4.
    Am I missing something here?  Any help would be greatly appreciated.
    Thanks,
    Curtis

    I was able to solve my issue. The field TDIMMED (print immediate) in the parameter OUTPUT_OPTION need to be passed with the value 'X'.
    The code is pasted below.
    DATA: l_ssfctrlop TYPE ssfctrlop,
            l_ssfcompop TYPE ssfcompop,
            l_formname  TYPE tdsfname,
            l_fm_name   TYPE rs38l_fnam.
      CLEAR l_formname.
    Get the smartform name based on the output type
      SELECT SINGLE sform FROM tnapr INTO l_formname
        WHERE kschl = ysdt_dynlayout-auart
          AND nacha = '1'
          AND kappl = 'V2'.
      Get the smartform function module name
        CLEAR l_fm_name.
        CALL FUNCTION 'SSF_FUNCTION_MODULE_NAME'
          EXPORTING
            formname           = l_formname
          IMPORTING
            fm_name            = l_fm_name
          EXCEPTIONS
            no_form            = 1
            no_function_module = 2
            OTHERS             = 3.
        IF sy-subrc EQ 0.
          l_ssfctrlop-no_dialog = 'X'.                        " print popup dialog box is suppressed
          l_ssfcompop-tddest    = usr01-spld.         " the printer name is passed from screen to this field
          l_ssfcompop-tdimmed   = 'X'.                    " print immediate option is set
          l_ssfcompop-tdcopies  = copies_in.         " number of copies of output required
        Call the smartform
          CALL FUNCTION l_fm_name
            EXPORTING
              control_parameters = l_ssfctrlop
              output_options     = l_ssfcompop
              user_settings      = ' '                            "manual override of user settings            
              i_del_head         = likp
              i_dyn_layout       = ysdt_dynlayout
            TABLES
              t_del_item         = ig_lips
              t_home_address     = ig_home_address
              t_header_text1     = ig_header_text1
              t_footer_text1     = ig_footer_text1
              t_footer_text2     = ig_footer_text2
              t_footer_text3     = ig_footer_text3
              t_text4            = ig_text4
              t_text5            = ig_text5
            EXCEPTIONS
              formatting_error   = 1
              internal_error     = 2
              send_error         = 3
              user_canceled      = 4
              OTHERS             = 5.
        ENDIF.

  • Chinese character overlap in PDF file

    Hi guyz,
    I am working on the issue on Chinese character overlap in PDF file.
    There is smartform which is being used to generate ePaySlip(Comes in email) in PDF file format which contains Chinese and English both characters.
    Now the issue is that at the bottom of the ePaySlip there is a Remark section which is maintained in Chinese and English both. However, the English sentences are proper withour any problem whereas the same thing in Chinese is showing as distorted/overlapped in few words.
    Can anyone suggest what could be the cause and suggest some solution.
    As when I checked in smartform those characters are hard coded and Chinese characters are shown as ###.
    Please response, I would be really grateful.
    Thanks & Regards,
    Mini

    Hi,
    there a different things to know.
    I produce sapscript forms with cinese and english characters for frontend / backend and archiv printing.
    Please check:
    Editor displays ###: You have to install the chinese language in your e.g. windows-system to display them.
    Script: You have to chose the the font family "CNSONG" (customized for chinese simplified and LATIN).
    Transaction I18N: May you have to set correct subfonts for the unicode areas (Cascading fonts, Standard is Courier).
    You can print in different ways:
    For archiv/PDF: Install the unicode truetype font with chinese characters for the pdf-converter.
    For Frontend: Use the Frontendprinter SAPWIN or SAPWIN*CF (Cascading Font) to send it to the gui (note: SAPLPD does not support it, use the newer technology.....)
    Backend printing: POSTSCRIPT is not yet implemented :-((
    PLease note: What you see in spool / print preview is a simulation of the possible print, but backend print is not frontend preview!!!!
    Regards,
    Christian

  • Problem with chinese character for dot matrix epson LQ-1600K III

    Hi All,
    I really runs out of idea about my problem now. The problem is about Print Chinese character to dot matrix printer (Epson LQ-1600K III). I tried to so many device type to solve this issue, looks like the only device type can be use are CNSAPWIN and CNEPSON with CNSONG font type. The others if I print to the printer, the chinese character became # (although in the print preview it`s okay and display correctly).
    Here is the bottleneck if I use CNEPSON:
    - if I have 2 window at the left and right position, if the left window has chinese character, the right window automatically shift right about 1.5 CM, which is damn weird!!! Can somebody help me
    - I tried so many ways to adjust the line size for my detail window (to cater positioning at pre-printed boxes), but looks the font size always become 10pt and line size cannot be adjustable (based on smartstyle).BUT if I used device type epescp2, it can be done!
    Here is the bottleneck if I use CNSAPWIN:
    - I need to create format type in windows and SAP (SPAD). and every PC that use this printer, must define the Paper size ( China Special paper size 12inch)
    - I also think this is not a good idea because as I far as I know this is not the correct way..
    Therefore, if somebody has experience about printer chinese character to dot matrix for Smartform and sapscript..please kindly help me give some advice.
    Do I use the wrong device type?
    Thanks in advance!
    Regards,
    Willy

    Hi friends , we are using the same model ....
    Are you using the chinese version operation system ? because we can print the chinese charaters without problem in LQ 1600KIII .....
    We are using CNSAPWIN device type + Frondend printing access method ....
    Carlos Zhang

  • Unable to display Chinese character in non-unicode system properly.

    Hi, all
    My system has been upgraded from 4.6C to 6.0 which is non-unicode system. Chinese characters with long length will be cut and cannot wrap automatically. But it's OK to alphabetes. How could I resolve this?
    Thanks..
    TD. Wei

    The simple and easy way to check
    non-unicode character sets are not supported on unicode system any longer. Am I right?
    Transaction code i18N
    Select
    trouble shooting --> printing  test --> smartforms --> multiple scripts, select your output device and see print preview. it will display all supported characters.
    I guess, above information will be useful for closing the thread.
    Regards,
    SaiRam

  • To print the Smartforms in Hindi

    Dear All,
    My latest requirement is to print the Smartforms in Hindi. Can anyone please guide me through this?
    Thanks in advance.
    Regards,
    Sourav

    Hi Sourav,
    This question had been discussed earlier though no concrete solution was posted.
    Still you might find a few helpful posts.
    Follow this link :
    Re: SAPScript in different language
    Regards.

Maybe you are looking for