Opening a Print Queue

  • Thread starter Thread starter Andy
  • Start date Start date
A

Andy

Hi,

Does anyone know if there is a way to open the print queue dialog for a
specified printer?

I already know what the printers name is (e.g. \\server\printer1) but I
would like to be able to show the standard Windows print queue dialog.

Thanks,

Andy
 
Hi Andy,

I am afraid the .NET Framework doesn't support to open a Print Queue
dialog. If you need a workaround on this issue, I suggest you consult this
issue in our corresponding Win32 SDK or Shell specific newsgroups, you may
receive some suggestions from there.

Thanks!

Best regards,

Gary Chang
Microsoft Online Community Support
==================================================
When responding to posts, please "Reply to Group" via your newsreader so
that others may learn and benefit from your issue.
==================================================
This posting is provided "AS IS" with no warranties, and confers no rights.
 
Anyone had any thoughts on this?

There must be an API somewhere that can allow me to open the print queue
UI...

Thanks!

Andy
 
OK, I've worked this out myself:
using System.Diagnostics;

Process myProcess = new Process();

myProcess.StartInfo = new ProcessStartInfo(@"\\server\printer1", "");

myProcess.Start();

Thanks!

Andy
 
Andy said:
Anyone had any thoughts on this?

There must be an API somewhere that can allow me to open the print queue
UI...

Something like

[DllImport("shell32.dll")]
static extern int SHInvokePrinterCommand(IntPtr hwnd, uint uAction, string
lpBuf1, string lpBuf2, bool fModal);
const uint PRINTACTION_OPEN = 0;

....

SHInvokePrinterCommand(Handle, PRINTACTION_OPEN, "your-printer-name-here",
null, false);


Might do..

Bit more in

http://msdn.microsoft.com/library/e...nctions/shinvokeprintercommand.asp?frame=true
 

Ask a Question

Want to reply to this thread or ask your own question?

You'll need to choose a username for the site, which only take a couple of moments. After that, you can post your question and our members will help you out.

Ask a Question

Back
Top