Need Help Selecting a Specific Printer in MS Access

I'm in the process of converting a MS Access 2K compiled application that was developed to run on XP so that it will also run on Win 10 computers.
Our goal is to get the application to run on both platforms so we do not have to replace all of our machines.

 (We understand the risks in using XP machines and have taken steps to mitigate them, so please help me solve this problem rather than tell me why I should not use XP).

The problem is that when XP connects to a networked printer then printer name assigned is "printername on servername": for example, "Shipping on FileServerPro".
When I generate a report in MS Acesss I have the option of selecting the default printer or a specific printer.  Each employee has a printer near his or her desk that is set up as the default printer.  Reports that need to print to the shipping print are hardcoded to print on "Shipping on FileServerPro".

Windows 10 uses a different naming convention for network printers, causing the printer name to appear simply as "Shipping" in the Printers and Faxes section.

As a result, when the MS Access code is executed in attempt to print to the shipping printer, we get an error message which essentially states that Access can not find "Shipping on FileServerPro" when run on Win 10 computers (of course this is because the Win10 computer knows the printer simply as Shipping).

I can make changes to the XP machines, or the Win10 machines, or to Access, but I need the same code to print to my networked shipping printer on both platforms.
Who is Participating?

[Product update] Infrastructure Analysis Tool is now available with Business Accounts.Learn More

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.

John TsioumprisSoftware & Systems EngineerCommented:
Well you could either iterate the installed printers and do a partial match on the device name or you could refer to it by IP bypassing the naming conventions.
pcalabriaAuthor Commented:
@john. Does Access allow me to do this?  The only way I know to select a specific printer is to open the form in design view, select page setup, then select specific printer on the middle tab, select a printer from the drop down.

The only printers that appear on the drop down are those installed for the computer.

Is there a way to do this through code?
John TsioumprisSoftware & Systems EngineerCommented:
In this article you can check how you iterate Printers collection.
After that you can set printer described like in this Ms Article
For a complete solution check Allen Browne PrintMgr

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
Determine the Perfect Price for Your IT Services

Do you wonder if your IT business is truly profitable or if you should raise your prices? Learn how to calculate your overhead burden with our free interactive tool and use it to determine the right price for your IT services. Download your free eBook now!

pcalabriaAuthor Commented:
@John  This looks very promising... I'm looking into it today... The code needs to work on both XP and Win10...currently we use Access 2K to compile...If I compile with a later version of Access I'm not sure what to do to get that new code to work on the XP machines, which also have a licensed version of Access 2K installed... any thoughts would be appreciated.
pcalabriaAuthor Commented:
More complicated than I had hoped (because access 2000 is not supported) but I'm still trying to work things out.
pcalabriaAuthor Commented:
It seems that my problem is actually caused by a driver issue, which we are addressing in another question.  Thanks for your continued help and support.
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
Windows 10

From novice to tech pro — start learning today.