Im trying to automate adding & installing an Add-In for Excel where the Add-In is located on a shared network drive. I know from my reading around the web (here and here) that I need to make the copy that's on the shared network drive Read-Only. And thanks to the first link I now know how I can go about making revisions, fixes, and additions to my Add-In down the road using this method of keeping the file on the shared network drive.
Now having an idea of the process, I started looking into how to automate the adding and installing of the Add-In once it's on the shared network drive. I came across this post, which pointed me in the right direction of using the Excel.AddIn
object. So, I was spending some time looking at the msdn documentation on the AddIn Object
properties (Installed Property and AddIn Object itself), which is where I found this bit of code that adds and installs the Add-In in one line
AddIns.Add("generic.xll").Installed = True
My question (and concern):
In the instructions below
Bullet point five has me slightly concerned because I have not been able to find out through my digging around the web if using the above code snippet to add and install the Add-In will copy it to the local/user's folder (which I don't want), keep it in the shared network folder, or if it will prompt the user just like when they manually browse to add the Add-In. If it prompts them is there any way to choose for them (to always click 'No') or is there a way to choose 'No' without showing them the prompt at all? How can I use the above code and make sure that it's adding and installing the Add-In file that's on that shared network drive? Can anyone shed some light on this situation for me?