Printers Object Not Exposed on Server

I have developed an application in Visual Basic 6 that will spawn multiple instances of the printing our company's billing statements.  It works great from a PC, but it fails when executed as a service through vb scripting.

When it fails, my error log shows that that the exe was uable to view the printers object.  The error number returned is #484 "Problem getting printer information from the system.  Make sure the printer is set up correctly."

The ap was developed on a Windows 200 PC, and the Server is Windows 2000, sp 4.

The really odd thing about this is that it will execute fine if I log into the server remotely and execute it using "Start | Run".

Who is Participating?
I wear a lot of hats...

"The solutions and answers provided on Experts Exchange have been extremely helpful to me over the last few years. I wear a lot of hats - Developer, Database Administrator, Help Desk, etc., so I know a lot of things but not a lot about one thing. Experts Exchange gives me answers from people who do know a lot about one thing, in a easy to use platform." -Todd S.

Is the service set to interact with the desktop?Have you tried setting the service to run under the administrator account or an account that has the printers set-up in the profile.
dgordenAuthor Commented:
No, the service is not supposed to interact with the desktop.  It does however read and write to an MS SQL database with no issues.

We have set up an NT account just for this process, and given the account Admin rights.  Rights to the printers have been given to the account.  The default printer is the Acrobat PDF Writer, and it has even been shared and set to "use printer off line".  

The underlying API to enumerate the printers cannot be called from a service.  You need to hard code the name of the printer (in a ini file?) or pass it in some other way.

Experts Exchange Solution brought to you by

Your issues matter to us.

Facing a tech roadblock? Get the help and guidance you need from experienced professionals who care. Ask your question anytime, anywhere, with no hassle.

Start your 7-day free trial
dgordenAuthor Commented:
Well, thanks for the help.  
It's not the answer I hoped for, but I will put this in an ini file.
It's more than this solution.Get answers and train to solve all your tech problems - anytime, anywhere.Try it for free Edge Out The Competitionfor your dream job with proven skills and certifications.Get started today Stand Outas the employee with proven skills.Start learning today for free Move Your Career Forwardwith certification training in the latest technologies.Start your trial today
Visual Basic Classic

From novice to tech pro — start learning today.