Not able to print a chinese word

Ranjith

New Member
I am able to store a chinese word into the progress DB.
I can see the word from GUI procedure editor also.

When i am trying give the print into an HP printer from GUI editor using the code

SYSTEM-DIALOG PRINTER-SETUP
NUM-COPIES 1.
output stream report to PRINTER PAGED.
PUT STREAM report CONTROL v-elite.

put stream report "登船日期" at 1
.

But its printing some other letters.
I tried saving the same word as a .txt file (encoding UTF-8) and i gave the print.That time i am getting the exact print.

Can someone help me to solve this problem
 
Most likely your are hitting a code page issue. The client ( procedure editor ) is started with its distinct code page and the database has also a code page defined. Both code pages must support the Chinese characters you want to use. Progress automatically tries to convert between code pages when they are different - but there will only be a successful conversion when the two code pages are compatible ( sharing the same character set ).

Most likely you need to start your client ( procedure editor ) with UTF-8 code page and if you want to store such characters in the database you need to convert your database to UTF-8 too if it is not already converted.

For the client you can use -cpinternal and -cpstream command line parameters. You might also have a look into the startup.pf file that resides in your installation directory. In there the code page which was chosen during the installation is defined.

For the database you might want to look into http://knowledgebase.progress.com/articles/Article/P97787 to see what the database uses.

Heavy Regards, RealHeavyDude.
 
Thankyou for your reply.
The progress DB is converted to UTF-8 and i started the DB with parameters
-cpinternal utf-8
-cpstream utf-8

Also the client procedure editor is started with same parameters.
I can save a chinese word into DB from client procedure editor.
Also i can display the same in client procedure editor.

The issue is with giving a print from client procedure editor.
The code i am using is

SYSTEM-DIALOG PRINTER-SETUP
NUM-COPIES 1.
output stream report to PRINTER PAGED.
PUT STREAM report CONTROL v-elite.

put stream report "登船日期" at 1

where v-elite is a escape command which is initialised by 'e&k4s'.
I am not much used with these printer commands.
Please help
 
Back
Top