Mike Feng over at the .Net libraries forum has asked me to repost my question on this forum, so here it is.......
I have fully functioning and stable XPS creation (.Net 4) and printing (.Net 4.5) server side web services, however I do have one issue. I also have an admin web site (asp.net mvc 4 on IIS7.x) that iterates through my client's print servers, extracting the print queues and retrieving the print capabilities (queue.getprintcapabilitiesasxml) which are then deposited in an SQL database for print job use. This site is run when support adds or removes printers or changes printer drivers on print servers so that the tray namespaces and URIs are always correct for each printer.
The issue is this...When I run this admin code from VS2010 (.Net 4) on my desktop (win 7 x64)everything works correctly and I receive all the printer information I require, however when I deploy to IIS (7.5 2008 R2) and run the site, one print server (virtual 2008 R2) reports that "Print ticket service failed to bind to printer Win 32 Error: Unknown printer driver" for the printers I'm targeting (Sharp printers). As stated, this print server is virtual whereas the others are real and Sharp printers exist on the other print servers. I thought this might be a permissions issue so I tried running the site's app pool identity as my own domain account, which didn't work, so I tried impersonation and that didn't work. The virtual print server flat out refuses to pass info back to the IIS server but will happily pass it back to my desktop (all other things being equal). I'm at a bit of a loss on how to investigate this, so I'm asking for help here.
UPDATE: The server in question is 32 bit 2003 virtual, however the printing web service that talks to it is .Net 4.5 anyCPU and is able to modify create job scoped, tray targeted user print tickets on that server using the namespace and URI data without issue.
It is only when queue.getprintcapabilitiesasxml on the admin service is called do I have issues, so it is kinda wierd that one service wont give the data but another service can use the data to manipulate tickets. Both services are on the same IIS server but under different host headers.
I still haven't tried Mike's response below as I'm not on site.
He's given me the response below, which I've yet to try, however if anyone can provide any extra info I'd appreciate it.....
I would like to suggest you to enable 32bit application on 64bit IIS: http://www.microsoft.com/technet/prodtechnol/WindowsServer2003/Library/IIS/405f5bb5-87a3-43d2-8138-54b75db73aa1.mspx?mfr=true
And for further more information, please try IIS forum: http://forums.iis.net/ Since this issue is more related to IIS setting.