I have a web method that renders a SQL Reporting Services report and prints it to a network printer using the System.Drawing and System.Drawing.Printing namespaces in .Net 2.0. This method has been working without issues in production at several client sites but now I've started seeing memory errors when trying to print. The only way to resolve the errors has been to do an IISReset on the web server hosting the web service. I tried calling Microsoft support for assistance in troubleshooting the issue and found out that using System.Drawing in an ASP.Net application, ASP.Net Web Service and in a Windows Service is not supported. Does anyone have any alternative ways to print from a web service to a network printer? I'm trying to find a managed code way of doing this but I'm not finding anything but System.Drawing.Printing. Thanks for the help. Mark
Hi John, Thanks for the response! The thought of using a Windows Service crossed my mind too as an alternate but that is not supported either. Any other thoughts? My only other idea so far is to write a console application that does the printing and have my web method start the console app with the appropriate parameters. It just seems like there has to be a better way. Thanks for any ideas! Mark
"Mark624" wrote in message news:3F9E4149-7D8C-41B9-8827-1B98980B5B9D@microsoft.com... > Hi John, > > Thanks for the response! The thought of using a Windows Service crossed > my > mind too as an alternate but that is not supported either. Any other > thoughts? My only other idea so far is to write a console application > that > does the printing and have my web method start the console app with the > appropriate parameters. It just seems like there has to be a better way. Another set of alternatives would be to use either .NET Remoting or Windows Communications Framework (WCF) to talk to a "Windowless" Windows Forms application. This would be a normal Winforms application except that it would not display its form. Both Remoting and WCF can be hosted in this sort of application. The question for your Microsoft contacts is whether or not the window is required for printing to be supported, or if it only needs to be in a Windows Forms application. -- John Saunders [MVP]