CodeGuru Home VC++ / MFC / C++ .NET / C# Visual Basic VB Forums Developer.com
Results 1 to 2 of 2
  1. #1
    Join Date
    Feb 2004
    Location
    Germany
    Posts
    153

    Printing Unicode Direct

    Hi there,

    I have a problem with printing unicode text.
    In my (UNICODE) Application I have to print a protocoll directly to the printer. I do this via OpenPrinter() and then WritePrinter() with the text direct. This works fine as long as I have only ascii characters in my text.

    Now the situation came up, where I had to print special characters ( some east european one like š and ė). With those characters the printout produced only rubbish, even when i encoded my string to utf8 before.

    The question is now: Is there any chance to tell the printer that he has to use a special codepage or that he has to interpret the text i send as utf8 ???

    Any hints are welcome,
    Thanks Matze

  2. #2
    Join Date
    May 2002
    Posts
    1,435

    Re: Printing Unicode Direct

    I am certainly not an expert on this subject, but I guessed that if something like this were to be done on a universal basis (i.e. works for all printers) it would be done via escape characters.

    Based on that guess I did a quick search and found that the ISO-2022 standard seems to cover precisely what you want to do.

    There may be others here who can help, but I would also suggest a Google search on ISO-2022 and UTF8.

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •  





Click Here to Expand Forum to Full Width

Featured