Printing issue

L

laguna.noir

Hello all

When printing from Enterprise Service I've got strange exception:

System.ComponentModel.Win32Exception: The operation completed
successfully

Server stack trace:
at System.Drawing.Printing.PrinterSettings.GetHdevmodeInternal()
at System.Drawing.Printing.PrinterSettings.GetHdevmode(PageSettings
pageSettings)
at
System.Drawing.Printing.PrintController.OnStartPrint(PrintDocument
document, PrintEventArgs e)
at
System.Windows.Forms.PrintControllerWithStatusDialog.OnStartPrint(PrintDocument
document, PrintEventArgs e)
at System.Drawing.Printing.PrintController.Print(PrintDocument
document)
at System.Drawing.Printing.PrintDocument.Print()

It appears only when printing on some printers, with others it works
well. Also, I tried to print the same image on the same printer using
the standard Windows image viewer and had no any problems. What could
be the source of this exception?
 
G

Guest

Hello all

When printing from Enterprise Service I've got strange exception:

System.ComponentModel.Win32Exception: The operation completed
successfully

Server stack trace:
at System.Drawing.Printing.PrinterSettings.GetHdevmodeInternal()
at System.Drawing.Printing.PrinterSettings.GetHdevmode(PageSettings
pageSettings)
at
System.Drawing.Printing.PrintController.OnStartPrint(PrintDocument
document, PrintEventArgs e)
at
System.Windows.Forms.PrintControllerWithStatusDialog.OnStartPrint(PrintDocu­ment
document, PrintEventArgs e)
at System.Drawing.Printing.PrintController.Print(PrintDocument
document)
at System.Drawing.Printing.PrintDocument.Print()

It appears only when printing on some printers, with others it works
well. Also, I tried to print the same image on the same printer using
the standard Windows image viewer and had no any problems. What could
be the source of this exception?

Are you trying to print to a local printer from ASP.NET?
 
L

laguna.noir

Are you trying to print to a local printer from ASP.NET?- Hide quoted text -

- Show quoted text -

No. I'm trying to print to the network printer and not from ASP.NET
yet. By security requirements we moved printing logic to the
Enterprise Service (COM+ component) which is being called from
ASP.NET. The web page passes network printer name and the file to
print as parameters of the method and the Enterprise Service do the
job. The network printer is accessible from the web-server, that's for
sure. I successfully printed being logged in to the server as the same
account as Enterprise Service is running.
 
L

laguna.noir

Are you trying to print to a local printer from ASP.NET?- Hide quoted text -

- Show quoted text -

No. I'm trying to print to the network printer and not from ASP.NET
yet. By security requirements we moved printing logic to the
Enterprise Service (COM+ component) which is being called from
ASP.NET. The web page passes network printer name and the file to
print as parameters of the method and the Enterprise Service do the
job. The network printer is accessible from the web-server, that's for
sure. I successfully printed being logged in to the server as the same
account as Enterprise Service is running.
 

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

Members online

Forum statistics

Threads
473,969
Messages
2,570,161
Members
46,708
Latest member
SherleneF1

Latest Threads

Top