Results 1 to 2 of 2
Thread: VBA and Access database
2013-06-22, 05:20 #1
- Join Date
- May 2013
- Thanked 0 Times in 0 Posts
VBA and Access database
I'm working with Word 2010, VBA and Access 2010. My VBA queries a table and everything appears to work OK. I've also got all the correct References set in the VBA Editor.
I now want to give my template and database file to my friend to use. He's got Word 2010 in the Home edition which means he doesn't have Access. So my first question is: does he need Access on his system for my template to work or will it work just having the database file?
My second question lies with the References I've set in the VBA Editor. When I pass the template to him will his system read the references I've set for my template to work correctly and query the database file? (Yes, I know you could say "Try it and see what happens!" but I'm trying to be a little prepared before the event so I know what I need to look for should it not work as I might expect).
Thanks for any help you can give me on these points.
2013-06-23, 10:41 #2
- Join Date
- Sep 2011
- Oklahoma City, OK
- Thanked 31 Times in 30 Posts
Welcome to the world of software development and deployment!
Building Office based applications to run on other people's machines does require a lot of extra testing and tweaks to the way you code stuff. For instance, using Late Binding helps solve reference issues. You may also have to build in tools to modify paths. When you create stuff for others, it does require more work and lots of testing.
What is the database format for the Access file? Is it a .mdb (JET) or .accdb (ACE)?
You will need the Access database drivers for the format you are using. The good news is the JET (.mdb) format drivers are already installed with Windows. The ACE (.accdb) drives must be installed. See: Microsoft Access Database Engine 2010 Redistributable (Click Here)
If it were mine, I would use the .MDB format. It will make the deployment a lot simplier. No extra stuff to install.
FYI: There is the free Access Runtime available for download from Microsoft. See: What is the Access Runtime Version?
Without seeing and testing your template it will be hard to say for sure what issues you may have.
There really is no way to know without seeing it and trying it.
Testing is a major part of good programming. You will learn a lot more if you will "Try it and see what happens!"
FWIW: I develop on a Windows 7 Pro 64-bit PC. I have XP-Mode set up and also several other Virtual Machines (VM) just for testing.Boyd Trimmell aka HiTechCoach (Access Information here)
Microsoft MVP - Access Expert
"If technology doesn't work for people, then it doesn't work."