What printer is chosen in CommonDialog when not default 
Author Message
 What printer is chosen in CommonDialog when not default

I would like to use the VB commondialog to select a
printer without setting the printer and other properties
to be default (dlgPrint.PrinterDefault=False).  I know I
can return the Information Context by setting flags but
how do I use the IC to determine what printer was chosen
from the list?  The dialog itself has no such property.  I
can use GetDeviceCaps to get information about the printer
but I don't think the printer name or printer driver is
part of that.  Does anyone know how to get the printer or
device name?

Greg Hatfield



Mon, 05 Apr 2004 11:56:39 GMT  
 What printer is chosen in CommonDialog when not default

Hello Greg,

No, I don't think this can be achieved through commondialog, but you can
try EnumPrinters API.

Hope it helps. If you have any questions, please reply to this post.

Best Regards,

Lily Zheng

Microsoft Support

Want to know more? Check out the MSDN at msdn.microsoft.com or the
Microsoft Knowledge Base at support.microsoft.com

This posting is provided "AS IS" with no warranties, and confers no rights.
You assume all risk for your use. Copy right, 2001 Microsoft Corporation.
All rights reserved.

--------------------
| Content-Class: urn:content-classes:message


| Subject: What printer is chosen in CommonDialog when not default
| Date: Wed, 17 Oct 2001 20:56:39 -0700
| Lines: 13

| MIME-Version: 1.0
| Content-Type: text/plain;
|       charset="iso-8859-1"
| Content-Transfer-Encoding: 7bit
| X-Newsreader: Microsoft CDO for Windows 2000
| X-MimeOLE: Produced By Microsoft MimeOLE V5.50.4522.1200
| Thread-Index: AcFXiOQn3aviMNCWTp6FYVGT7FOP2Q==
| Newsgroups: microsoft.public.vb.controls
| NNTP-Posting-Host: TKMSFTNGXA04 10.201.232.163
| Path: cppssbbsa01.microsoft.com!tkmsftngp01!cpmsftngxa10!cpmsftngxa07
| Xref: cppssbbsa01.microsoft.com microsoft.public.vb.controls:119281
| X-Tomcat-NG: microsoft.public.vb.controls
|
| I would like to use the VB commondialog to select a
| printer without setting the printer and other properties
| to be default (dlgPrint.PrinterDefault=False).  I know I
| can return the Information Context by setting flags but
| how do I use the IC to determine what printer was chosen
| from the list?  The dialog itself has no such property.  I
| can use GetDeviceCaps to get information about the printer
| but I don't think the printer name or printer driver is
| part of that.  Does anyone know how to get the printer or
| device name?
|
| Greg Hatfield
|
|



Fri, 09 Apr 2004 22:24:34 GMT  
 
 [ 2 post ] 

 Relevant Pages 

1. Choosing a printer during run-time (other than default) - Crystal Report 9 (CR 9)

2. CommonDialog.ShowPrinter changes default printer

3. Printer, default or not default ?

4. CommonDialog.ShowPrinter changes default printer

5. Printing to a printer that is NOT the default printer

6. Problem printing to printer wich is not the default printer

7. How To Get Printer Dialog Not to Change Default Printer

8. Printer object not applying to the default printer ???

9. Macro to change default printer and then restore original default printer settin

10. printer default to non-default printer

11. CommonDialog Printer Setup not working properly in Win2K

12. Help: How to choose Directory (instead of files) using CommonDialog ctl

 

 
Powered by phpBB® Forum Software