+ Reply to Thread
Results 1 to 5 of 5

Uninstall Add-in

  1. #1
    Forum Contributor
    Join Date
    08-19-2009
    Location
    Netherlands, Amsterdam
    MS-Off Ver
    Excel 2010
    Posts
    585

    Uninstall Add-in

    Hello all,

    I use the following code as a add-in

    Please Login or Register  to view this content.
    And this is the macro it reffers to:

    Please Login or Register  to view this content.
    The problem with it is, that it does not uninstall the add-in. even after closing down excel.
    Any ideas?

  2. #2
    Forum Expert royUK's Avatar
    Join Date
    11-18-2003
    Location
    Derbyshire,UK
    MS-Off Ver
    Xp; 2007; 2010
    Posts
    26,200

    Re: Uninstall Add-in

    Not sure what you mean. An addin is always available if installed correctly. This event:
    Workbook_AddinUninstall, does not install an addin, it runs when the addin is installed. Likewise the uninstall part only works when an addin is uninstalled.

    Are you actually working with an addin that is installed correctly? Addins will have a *.xla or for versions later than 2007, a *.xlam extension.

    If you want the menu to install each time the workbook is opened then use the WorkBook_Open event and the Workbook_BeforeClose event

    Your code adds a Commandbar not an installation, this will only be visible in versions before Excel 2007, after that you will need to open the addins tab
    Hope that helps.

    RoyUK
    --------
    For Excel Tips & Solutions, free examples and tutorials why not check out my web site

    Free DataBaseForm example

  3. #3
    Forum Contributor
    Join Date
    08-19-2009
    Location
    Netherlands, Amsterdam
    MS-Off Ver
    Excel 2010
    Posts
    585

    Re: Uninstall Add-in

    Hello Roy,

    This is the first time I'm working with it
    It has a XLA-extension [I am using 2003]

    What I a actually like to accomplish is that the add-in needs to be selected [installed] each time your'e going to use it [or at least doesn't appear on the menu-bar unless selected]
    This because when it is hit on a wrong sheet it will destroy the sheet.

    Although I am not sure if it can be called a add-in but the MrExcelHtmlMaker would be the best solution.
    It needs to be doubleclicked each time your'e going to use it and will uninstall itself upon closing down excel.

  4. #4
    Forum Expert royUK's Avatar
    Join Date
    11-18-2003
    Location
    Derbyshire,UK
    MS-Off Ver
    Xp; 2007; 2010
    Posts
    26,200

    Re: Uninstall Add-in

    The simplest solution is to make the code check the correct page is selected, or better still don't write the code as you have so that it acts on the ActiveSheet. You should specify the sheet in the code. This might work better

    Please Login or Register  to view this content.

  5. #5
    Forum Contributor
    Join Date
    08-19-2009
    Location
    Netherlands, Amsterdam
    MS-Off Ver
    Excel 2010
    Posts
    585

    Re: Uninstall Add-in

    It gives an error on line: [Method "Delete" of object'_CommandBarButton' failed]

    Please Login or Register  to view this content.
    btw. the name of the sheet is not always the same as it is used on a file imported from another program.

+ Reply to Thread

Thread Information

Users Browsing this Thread

There are currently 1 users browsing this thread. (0 members and 1 guests)

Bookmarks

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts

Search Engine Friendly URLs by vBSEO 3.6.0 RC 1