Click here to Skip to main content
15,742,973 members
Please Sign up or sign in to vote.
0.00/5 (No votes)
See more:
Hi everyone
I have a problem in printing farsi character in thermal printer(Bixolon Srp 350 plus).The company provide a class in c# to send string to the printer to print , but when I send farsi character it prints '?' instead of farsi character.They told me that I should change code page to farsi font , But I dont know how can I do that in c# . The Command to change code page to farsi is something like this ( 1b 74 1b ) in Hex value . There is something else : When I print by using Wordpad it prints fine . Please help me.
Thanks a lot.

You print your Wordpad documents in graphic mode. This is good.

How do you know your printer supports Unicode (which is used by .NET) in character mode? I suspect it does not: the whole notion of code page is from the pre-Unicode epoch. However, for compatibility with obsolete encoding and code pages, the Windows code page 1200 is attributed to Unicode. (Do you try it?)

You really need to print in graphics mode. Using Farsi with Unicode and .NET is never a problem. More exactly, if you're talking about modern Farsi, it's a Perso-Arabic script, see[^].

Use the class System.Drawing.Printing.PrintDocument. For the code sample, see[^].

Share this answer
mojtaba pirveisi 24-May-11 14:44pm    
Thank you very much . I used printdocument and it did work . Perfect Solution!!!
Thanks again.
Sergey Alexandrovich Kryukov 24-May-11 14:53pm    
Great. My pleasure.
Did you use PrintDocument?
Thanks for accepting this solution (a vote won't hurt as well).

Good luck, call again,
hello ,when i print with thermal printer in report viewr ,does not cut between first page and second page ,please help me
Share this answer

This content, along with any associated source code and files, is licensed under The Code Project Open License (CPOL)

CodeProject, 20 Bay Street, 11th Floor Toronto, Ontario, Canada M5J 2N8 +1 (416) 849-8900