Installing an Addin

Giordano Bruno

Well-known Member
Joined
Jan 7, 2007
Messages
1,356
I have the following code (Called from another macro)

On Error Resume Next
Addins("ACME").Installed = True

The code stops at the second line with a Run-time eror 9 Subscript out of range.

The file ACME.xlam is visible in the VBA Project window.

Question 1. Why does the code not resume next.

Question 2. Why does the code create an error

I'm using Excel 2007

Any suggestions will be gratefully received.
 

Excel Facts

Get help while writing formula
Click the italics "fx" icon to the left of the formula bar to open the Functions Arguments dialog. Help is displayed for each argument.
Just to add to the above, If I stop the code at the point where the error occurs and re-run the macro, the Addin is installed properly.

If I make a second macro which does nothing but call the first macro, the error returns.

It seems that the problem occurs only when the Addin macro is called from another macro.
 
Upvote 0
This thread is becoming a mess. Ignore the second post.

What happens is that although the code stops; if I click End instead of Debug the Addin is ticked, despite the error message. When the addin is ticked, the code runs past that line without stopping. It seems that all I need is a method of getting past the error without the message stopping the code.
 
Upvote 0

Forum statistics

Threads
1,224,582
Messages
6,179,670
Members
452,936
Latest member
anamikabhargaw

We've detected that you are using an adblocker.

We have a great community of people providing Excel help here, but the hosting costs are enormous. You can help keep this site running by allowing ads on MrExcel.com.
Allow Ads at MrExcel

Which adblocker are you using?

Disable AdBlock

Follow these easy steps to disable AdBlock

1)Click on the icon in the browser’s toolbar.
2)Click on the icon in the browser’s toolbar.
2)Click on the "Pause on this site" option.
Go back

Disable AdBlock Plus

Follow these easy steps to disable AdBlock Plus

1)Click on the icon in the browser’s toolbar.
2)Click on the toggle to disable it for "mrexcel.com".
Go back

Disable uBlock Origin

Follow these easy steps to disable uBlock Origin

1)Click on the icon in the browser’s toolbar.
2)Click on the "Power" button.
3)Click on the "Refresh" button.
Go back

Disable uBlock

Follow these easy steps to disable uBlock

1)Click on the icon in the browser’s toolbar.
2)Click on the "Power" button.
3)Click on the "Refresh" button.
Go back
Back
Top