G
Guest
Yesterday you helped me to determine how to install an add-in through vba,
thank you for that.
Now I am trying to get past the alert boxes which ask if I would like to
overwrite the add-in if it currently exists. The two messages I get are:
"Copy XXXX.xla to the add-ins folder?" (Yes/No/Cancel), and "A file named
XXXX.xla already exists. Do you want to replace it?" (Yes/No/Cancel).
Is there a way to program the code not to ask these questions? It will not
work if I set Application.DisplayAlerts = False because it defaults to
answering "No." Or at least the way I have it running. How can I correct the
code to answer "Yes," but not display the alerts? Below is an example of what
I am currently using.
Thank You,
Sub AdinInstall1A()
Application.DisplayAlerts = False
On Error Resume Next
Application.AddIns.Add Filename:="C:\XXXX.xla"
Application.AddIns("XXXX").Installed = True
Application.DisplayAlerts = True
End Sub
thank you for that.
Now I am trying to get past the alert boxes which ask if I would like to
overwrite the add-in if it currently exists. The two messages I get are:
"Copy XXXX.xla to the add-ins folder?" (Yes/No/Cancel), and "A file named
XXXX.xla already exists. Do you want to replace it?" (Yes/No/Cancel).
Is there a way to program the code not to ask these questions? It will not
work if I set Application.DisplayAlerts = False because it defaults to
answering "No." Or at least the way I have it running. How can I correct the
code to answer "Yes," but not display the alerts? Below is an example of what
I am currently using.
Thank You,
Sub AdinInstall1A()
Application.DisplayAlerts = False
On Error Resume Next
Application.AddIns.Add Filename:="C:\XXXX.xla"
Application.AddIns("XXXX").Installed = True
Application.DisplayAlerts = True
End Sub