Print Page | Close Window

Wide characters in a printer name causes crash

Printed From: Debenu Quick PDF Library - PDF SDK Community Forum
Category: For Users of the Library
Forum Name: I need help - I can help
Forum Description: Problems and solutions while programming with the Debenu Quick PDF Library and Debenu PDF Viewer SDK
URL: http://www.quickpdf.org/forum/forum_posts.asp?TID=2512
Printed Date: 22 Nov 24 at 6:44PM
Software Version: Web Wiz Forums 11.01 - http://www.webwizforums.com


Topic: Wide characters in a printer name causes crash
Posted By: Xan
Subject: Wide characters in a printer name causes crash
Date Posted: 24 Jan 13 at 8:06PM
Hello,

I'm developing a browser plugin that prints PDFs silently in the background.  Everything is working great, except for one minor issue: whenever the printer name contains anything other than ASCII, my plugin crashes completely when issuing a DPLPrintDocument command.  And I'm just using the normal DPLGetDefaultPrinterName(InstanceID) as the printer's name.  (I've also tried fetching the default printer myself into a string and passing that, with the same result.

I think this is unlikely to come up in the real world, but it does seem like a problem.  Has anybody else seen this?




Replies:
Posted By: Ingo
Date Posted: 24 Jan 13 at 8:48PM
Hi Xan!

It works like designed i fear.
Which version you're using?
If you look into the reference you can see that the activex-version returns with a string,
delphi- and dll-version with a widestring.
I think you should try the dll-version (widestring result)?

Cheers and welcome here, Ingo



Print Page | Close Window

Forum Software by Web Wiz Forums® version 11.01 - http://www.webwizforums.com
Copyright ©2001-2014 Web Wiz Ltd. - http://www.webwiz.co.uk