Kamis, 17 Maret 2016

[MS_AccessPros] Disable COm Addins via VBA


Hello, newbie member here.

I'm trying to figure out how or if I can disable/remove COM addins using VBA in MS Access.  I found an example of how to do it in Excel, but the example either doesn't work in Access or I'm coding something wrong (missing reference?).

First, some back ground.  The MS Access app itself is developed in Access 2003, runs under Windows 7 OS, but the majority of users run the front-end with Access 2010 published as a .mde.  It is a front/back-end set up using SQL Server back-end.  I chose to keep the master app in 2003 because I don't want a ribbon/tool bar, and I make extensive use of a custom Menu Bar that I manipulate during use.  The app is slowly being phased out over a thee year period, so I don't want to do a total rewrite.  I'm not a programmer, but have been developing apps in MS Access for 20 years.  It's a game (challenge) for me...

The issue is:  Some of my users use Adobe Acrobat Pro, which automatically adds a PDF menu to my custom Menu bar (and all other Office products installed).  I'm only interested in MS Access.  When someone with Acrobat Pro opens my app (and nobody else has it open), it gets opened exclusively because the Menu bar is modified.  This blocks everyone else out of the app until Acrobat Pro user closes it.  The COM add-in that causes this is called PDFMaker.  I can disable manually via options > add-ins, but would need to do so on each users machine and there a lot of potential users.

So what I would like to do is disable/remove this COM add-in when the app first starts (at a minimum), force the app to close itself (I can easily do this), then the app restart itself without the COM add-in (once its been disabled).  I could probably get by without it restarting itself.

Any thoughts on how to accomplish this would be appreciated, or maybe a better approach to tackle the issue....

I can post the Excel code I tried, if that helps.

Thanks in advance,



Posted by: kix_n_grins@hotmail.com
Reply via web post Reply to sender Reply to group Start a New Topic Messages in this topic (1)



Tidak ada komentar:

Poskan Komentar