Avatar of 4GvnNot4Gotn
4GvnNot4GotnFlag for United States of America asked on

Access 2013 - RunTime Compile: Missing References Excel 14-15

I have an Access 2013 (32 bit) app that I've developed.  It contains an export feature to "inject" data into Excel worksheets.

The problem I have is that I've compiled it using  a reference to the Microsoft Office 15.0 Object Library and Microsoft Excel 15.0 Object library (Office 2013).  When my users install it on their PC and have Office 2010  (which uses the Microsoft Office 14.0 Object Library and Microsoft Excel 14.0 Object library) the application throws an error on start-up and I have to go in manually, open VBA / Tools / References (shows Missing: Microsoft Office / Excel 15.0 Object Library) and set the reference back to Microsoft Office 14.0 Object Library and Microsoft Excel 14.0 Object library.

Works fine if the user has Office 2013 installed but breaks if the user has Office 2010 installed.  

I need a way to trap this error and set the references dynamically based on the version of Office they are using.

HELP!  This is causing a lack of confidence on the part of the client and I don't blame them.
Microsoft Access

Avatar of undefined
Last Comment

8/22/2022 - Mon
Rey Obrero (Capricorn1)

Log in or sign up to see answer
Become an EE member today7-DAY FREE TRIAL
Members can start a 7-Day Free trial then enjoy unlimited access to the platform
Sign up - Free for 7 days
Learn why we charge membership fees
We get it - no one likes a content blocker. Take one extra minute and find out why we block content.
See how we're fighting big data
Not exactly the question you had in mind?
Sign up for an EE membership and get your own personalized solution. With an EE membership, you can ask unlimited troubleshooting, research, or opinion questions.
ask a question

Thanks for the note.  How do I check to see which version that they are using and bind to the references for that version at run-time (not just kick out an error)?

Great catch!  Thanks!
This is the best money I have ever spent. I cannot not tell you how many times these folks have saved my bacon. I learn so much from the contributors.