Home |
Search |
Today's Posts |
#1
![]()
Posted to microsoft.public.excel.programming
|
|||
|
|||
![]()
One thing, Err is an Object with various properties etc
I think you are looking for LastError = Err.Number NickHK "Trefor" wrote in message ... Below is a snippet of my code thanks to this forum. I am getting an Error =9 on the line marked *1, so I try and load the Addin, the below code completes without error, but the AddIn didnot load. This code has been working for about 10months now, I can't understand why it is not working now, any ideas? Dim WBName As String On Error Resume Next ' turn off error checking *1 WBName = Workbooks(DCMaster2).Name ' Check to see if AddIn is loaded and should return an error if the file is not loaded LastError = Err On Error GoTo 0 ' restore error checking If LastError < 0 Then ' the add-in workbook isn't currently open. Manually open it. ' On Error Resume Next Application.DisplayAlerts = False With AddIns.Add(Filename:=Application.UserLibraryPath & DCMaster2) .Installed = True End With -- Trefor |
Thread Tools | Search this Thread |
Display Modes | |
|
|
![]() |
||||
Thread | Forum | |||
Automaion Addin not loading properly!! | Excel Programming | |||
May be Automation AddIn loading problem!! | Excel Programming | |||
addin loading issue | Excel Discussion (Misc queries) | |||
Run Macro when loading addin | Excel Programming | |||
Changing the Name of an Addin and loading worksheets off a network drive | Excel Programming |