PC Review


Reply
Thread Tools Rate Thread

Cannot find a loaded VBA addin

 
 
Simon Reid
Guest
Posts: n/a
 
      2nd Oct 2009
Hi,

I have an addin, lets call it 'office2003addin.xla' which is loaded into
Excel on startup because it is in the %App data%\Microsoft\Excel\XLSTART
directory. The issue I have is that it conflicts with an office 2007 COM
addin that I have created which needs to call VBA procedures in another
addin, lets call it 'office2007addin.xlam'.

I am running VSTO code which calls the VBA. The aim is that before I call
any VBA code I first check that office2007addin.xlam is loaded, and if not
then I load it using Application.addins.

I also want to check that office2003addin.xla is not loaded, and if it is to
remove it. The problem is that office2003addin.xla is not listed as an
active Addin, is not included in the Application.Addins or
Application.Workbooks collections so I have no way of removing it, but yet if
I go to the VBA editor I can see it listed as a project, and it is loaded
since I can call functions it contains.

This is a bit of a strange situation, but we have the 2003 addin deployed to
a lot of machines and I cannot guarantee that it will be removed when we
install the new version of office.

Has anyone seen this before, and is there any way of removing the addin, or
at least telling if it is there (short of removing the file from the PC,
which I cannot do).
 
Reply With Quote
 
 
 
 
Mike Middleton
Guest
Posts: n/a
 
      2nd Oct 2009
Simon Reid -

As I recall, it's always the case that an XLA add-in loaded using File Open
or XLSTART does not appear in the add-ins list.

An alternative (instead of XLSTART) might be to put the add-in XLA file in
(Windows Vista):

C:\ Users \ UserName \ AppData \ Roaming \ Microsoft \ AddIns folder

or in (Windows XP):

C:\ Documents and Settings \ UserName \ Application Data \ Microsoft \
AddIns folder.

- Mike
http://www.MikeMiddleton.com



"Simon Reid" <(E-Mail Removed)> wrote in message
news282EF69-B627-45D2-8181-(E-Mail Removed)...
> Hi,
>
> I have an addin, lets call it 'office2003addin.xla' which is loaded into
> Excel on startup because it is in the %App data%\Microsoft\Excel\XLSTART
> directory. The issue I have is that it conflicts with an office 2007 COM
> addin that I have created which needs to call VBA procedures in another
> addin, lets call it 'office2007addin.xlam'.
>
> I am running VSTO code which calls the VBA. The aim is that before I call
> any VBA code I first check that office2007addin.xlam is loaded, and if not
> then I load it using Application.addins.
>
> I also want to check that office2003addin.xla is not loaded, and if it is
> to
> remove it. The problem is that office2003addin.xla is not listed as an
> active Addin, is not included in the Application.Addins or
> Application.Workbooks collections so I have no way of removing it, but yet
> if
> I go to the VBA editor I can see it listed as a project, and it is loaded
> since I can call functions it contains.
>
> This is a bit of a strange situation, but we have the 2003 addin deployed
> to
> a lot of machines and I cannot guarantee that it will be removed when we
> install the new version of office.
>
> Has anyone seen this before, and is there any way of removing the addin,
> or
> at least telling if it is there (short of removing the file from the PC,
> which I cannot do).


 
Reply With Quote
 
Peter T
Guest
Posts: n/a
 
      2nd Oct 2009
An addin only gets into the Addins collection if
- it's in the default addins path
(and/) or
- it exists in the Addin manager in one of two (installed or not installed)
registry locations

An Addin that exists in the Addins collection will automatically load on
startup (if not in XLstart) if it's Installed Property = True (changing to
False does not remove it from the collection).

Although somewhat odd, even though loaded addins do not apparently appear in
the loaded Workbooks collection, you can test if it is loaded like this
(irrespective as to whether it's in the addins collection)

On Error resume next
Set wb = Workbooks("myAddin.xla")
On Error goto 0

If not wb is Nothing then
' it's loaded
Else
'it's not
End If

Regards,
Peter T



"Simon Reid" <(E-Mail Removed)> wrote in message
news282EF69-B627-45D2-8181-(E-Mail Removed)...
> Hi,
>
> I have an addin, lets call it 'office2003addin.xla' which is loaded into
> Excel on startup because it is in the %App data%\Microsoft\Excel\XLSTART
> directory. The issue I have is that it conflicts with an office 2007 COM
> addin that I have created which needs to call VBA procedures in another
> addin, lets call it 'office2007addin.xlam'.
>
> I am running VSTO code which calls the VBA. The aim is that before I call
> any VBA code I first check that office2007addin.xlam is loaded, and if not
> then I load it using Application.addins.
>
> I also want to check that office2003addin.xla is not loaded, and if it is
> to
> remove it. The problem is that office2003addin.xla is not listed as an
> active Addin, is not included in the Application.Addins or
> Application.Workbooks collections so I have no way of removing it, but yet
> if
> I go to the VBA editor I can see it listed as a project, and it is loaded
> since I can call functions it contains.
>
> This is a bit of a strange situation, but we have the 2003 addin deployed
> to
> a lot of machines and I cannot guarantee that it will be removed when we
> install the new version of office.
>
> Has anyone seen this before, and is there any way of removing the addin,
> or
> at least telling if it is there (short of removing the file from the PC,
> which I cannot do).



 
Reply With Quote
 
Charles Williams
Guest
Posts: n/a
 
      3rd Oct 2009
An XLA which is opened (File Open or XLSTART) rather than loaded by the
Addin manager is a hidden workbook in the Workbooks collection.

regards
Charles
___________________________________
The Excel Calculation Site
http://www.decisionmodels.com

"Simon Reid" <(E-Mail Removed)> wrote in message
news282EF69-B627-45D2-8181-(E-Mail Removed)...
> Hi,
>
> I have an addin, lets call it 'office2003addin.xla' which is loaded into
> Excel on startup because it is in the %App data%\Microsoft\Excel\XLSTART
> directory. The issue I have is that it conflicts with an office 2007 COM
> addin that I have created which needs to call VBA procedures in another
> addin, lets call it 'office2007addin.xlam'.
>
> I am running VSTO code which calls the VBA. The aim is that before I call
> any VBA code I first check that office2007addin.xlam is loaded, and if not
> then I load it using Application.addins.
>
> I also want to check that office2003addin.xla is not loaded, and if it is
> to
> remove it. The problem is that office2003addin.xla is not listed as an
> active Addin, is not included in the Application.Addins or
> Application.Workbooks collections so I have no way of removing it, but yet
> if
> I go to the VBA editor I can see it listed as a project, and it is loaded
> since I can call functions it contains.
>
> This is a bit of a strange situation, but we have the 2003 addin deployed
> to
> a lot of machines and I cannot guarantee that it will be removed when we
> install the new version of office.
>
> Has anyone seen this before, and is there any way of removing the addin,
> or
> at least telling if it is there (short of removing the file from the PC,
> which I cannot do).
>



 
Reply With Quote
 
 
 
Reply

Thread Tools
Rate This Thread
Rate This Thread:

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is On
HTML code is Off
Trackbacks are On
Pingbacks are On
Refbacks are Off


Similar Threads
Thread Thread Starter Forum Replies Last Post
Addin not loaded after recompile DeskUser@gmail.com Microsoft Outlook Program Addins 1 22nd Sep 2008 02:09 PM
AddIn not loaded - .Net 3.5 DeskUser@gmail.com Microsoft Outlook Program Addins 1 12th Jun 2008 04:50 PM
Excel Addin not getting loaded Sarang Bapat Microsoft Excel Discussion 0 11th May 2006 06:57 PM
XLL addin not loaded! =?Utf-8?B?VGV0c3V5YSBPZ3VtYQ==?= Microsoft Excel Programming 6 22nd Oct 2004 02:54 PM
Addin Available but not loaded for Outlook XP Phil Microsoft Outlook Program Addins 4 19th Jan 2004 06:49 PM


Features
 

Advertising
 

Newsgroups
 


All times are GMT +1. The time now is 03:43 AM.