win32ui CreatePrintDialog

Chris Lambacher lambacck at
Sat Jul 16 00:08:35 CEST 2005


This question has come up a few times on the list with no one giving a public
answer.  How do you use CreatePrintDialog from win32ui?

About a year ago someone posted that:
dlg = win32ui.CreatePrintDialog(1538)

will give you the window, but the ok button does not work.

Diging into the source shows that the 1538 is being loaded as a template
resource.  The MSDN documentation does not say anything about this being
neccessary and in fact, other common dialogs provide this as an option, but
not a requirement.  Why is this made a requirement?  If it was not made a
requirement, would the dialog work?

Unfortunately I can't play with this because I don't have Visual Studio.  I
guess the logical next step, if the above worked, would be to add the
GetPrinterDC() method (and maybe some others) so that we can do something
useful with the dialog.


More information about the Python-list mailing list