I have this old component service (COM+ Application) that gets called and tries to print a document. It runs as a specific user that acts as a service account that is never actually logged on to. For some reason my debug output is showing 0 printers listed when I make the call to the COM+ App. However, if I open a command prompt as that user I can make the same call and see all the printers.
It's like it's requiring the profile to be loaded before printers are shown. Is there a way around this? Currently my only work around is to do something really crazy like schedule a task to run each day for 1 day that just runs cmd.exe /c "pause". I didn't have to do this in the past (this has been used for many years). I remember something about not unloading registry profiles that might have helped me. Is there anything that I can add to my application (com+ app) that could load the printers and make them available for me?