+ Reply to Thread
Results 1 to 12 of 12

Excel 2007 macros have stopped working

  1. #1
    Registered User
    Join Date
    12-14-2007
    Location
    Ventura, CA
    Posts
    7

    Excel 2007 macros have stopped working

    All my macros have suddenly started crashing Excel 2007 when I try to run any one of them. I can record a new macro but even that newly recorded macro will crash Excel.

    Service Pack 1 was downloaded and installed by Windows Update two days ago and I had successfully run macros after SP1 was installed.

    Today, it's a no go and I'm at a loss as to what may have caused this problem. I have not installed any software lately, other than the Windows updates on patch Tuesday.

    This is on a Vista Home Premium machine.

    When I try to run a macro, Excel crashes with this info:

    Please Login or Register  to view this content.
    I also get a MS Visual Basic dialog saying an automation error exception occurred. Excel will not close until I click the OK button on this dialog.

    I've been searching for a solution all morning with no luck. Any ideas on what may be causing this problem? I am doomed without these macros!

    Thanks in advance.

    Steve

  2. #2
    Forum Expert royUK's Avatar
    Join Date
    11-18-2003
    Location
    Derbyshire,UK
    MS-Off Ver
    Xp; 2007; 2010
    Posts
    26,200
    I can't find any reference to problems caused by SP1. Can you remove the update?
    Hope that helps.

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

    Free DataBaseForm example

  3. #3
    Registered User
    Join Date
    12-14-2007
    Location
    Ventura, CA
    Posts
    7
    Quote Originally Posted by royUK
    I can't find any reference to problems caused by SP1. Can you remove the update?
    I'll have to do a system restore. Vista won't let me uninstall SP1. It will let me remove other fixes installed on Tuesday, but not that service pack.

  4. #4
    Forum Expert royUK's Avatar
    Join Date
    11-18-2003
    Location
    Derbyshire,UK
    MS-Off Ver
    Xp; 2007; 2010
    Posts
    26,200
    Quote Originally Posted by altidude
    I'll have to do a system restore. Vista won't let me uninstall SP1. It will let me remove other fixes installed on Tuesday, but not that service pack.
    Why not try that then see if macros run?

  5. #5
    Registered User
    Join Date
    12-14-2007
    Location
    Ventura, CA
    Posts
    7
    Well, I restored the system to previous and macros are still broken! SP1 was definitely removed as the Excel version shown by "about MS Excel 2007" is the same as the version on my laptop which I have not yet updated to SP1.

    I'm going to reinstall all the hotfixes and Office SP1. Something else has gone wrong. I think next course of action is to remove the macro files out of XLSTART and let Excel create a new personal file. Maybe something has gotten corrupted on my system somehow.

    At least the laptop is still working for me.

    Thanks for the quick response to my problem. I really appreciate that.

    Steve

  6. #6
    Forum Expert royUK's Avatar
    Join Date
    11-18-2003
    Location
    Derbyshire,UK
    MS-Off Ver
    Xp; 2007; 2010
    Posts
    26,200
    I never use PERSONAL.xls myself, but do macros work in an ordinary workbook (*.xlsm)?

  7. #7
    Registered User
    Join Date
    12-14-2007
    Location
    Ventura, CA
    Posts
    7
    Quote Originally Posted by royUK
    I never use PERSONAL.xls myself, but do macros work in an ordinary workbook (*.xlsm)?
    I converted personal.xls to personal.xlsm when I upgraded from Office 2003 to Office 2007. This was done at least three months ago, maybe longer. I don't remember exactly when I upgraded to Office 2007 but it was quite a while ago.

    What I did most recently was to remove personal.xlsm from the xlstart folder then record a simple macro, letting Excel save the macro to the personal workbook. As soon as I try to run that new macro Excel crashes.

    I have a 2nd file with macros as well, webcdr.xlsm. If I try to run a macro in that file, Excel crashes.

    I think the Visual Basic dialog box is a big clue to the problem but it just doesn't tell me much. I'm not a VB guy and really all it says is "automation error, Exception occurred". I have to OK that box before Excel will shut down.

    I am now back to SP1 by the way.

  8. #8
    Registered User
    Join Date
    12-14-2007
    Location
    Ventura, CA
    Posts
    7
    When I click "Help" on the VB dialog box, I see this:

    Please Login or Register  to view this content.
    I've tried debugging the macro by stepping into it but the crash is immediate.

  9. #9
    Registered User
    Join Date
    12-14-2007
    Location
    Ventura, CA
    Posts
    7
    I just had a thought and tried recording a simple macro in Word. The macro records but Word crashes when I try to run the macro. So, whatever is wrong it's wrong with Office, not just Excel.

    I've tried a repair install of Office with no improvement. I suppose my next step is to uninstall Office completely then reinstall. That or live with the fact that macros just no longer run on my desktop and use the laptop for all Excel work.

  10. #10
    Registered User
    Join Date
    12-14-2007
    Location
    Ventura, CA
    Posts
    7
    I found and fixed the problem.

    After racking my brain, I remembered that I had been trouble shooting a problem where Windows Movie Maker crashes. It's a known problem when Nero is also installed on a system and every now and then I try the suggested fixes. One of the fixes suggested for this Movie Maker problem involved turning off data execution prevention (DEP) via the command prompt with bcdedit.exe. Well, it turns out that this is what broke my Office macros.

    The suggested fix for Movie Maker involved setting DEP to AlwaysOff. If that didn't fix the Movie Maker crash, the tip says to set DEP to AlwaysOn. It turns out that AlwaysOn is not the default for Vista. I compared the bcdedit output on my wifes' Vista laptop to my desktop then changed the desktop to match. Problem solved, macros run!

    In case this comes up for somebody else, the command line entry that got me back up and running was:

    bcdedit.exe /set {current} nx Optin

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

  12. #12
    Registered User
    Join Date
    12-01-2009
    Location
    Antwerp, Belgium
    MS-Off Ver
    Excel 2007
    Posts
    1

    Re: Excel 2007 macros have stopped working

    Years after the posted problem and solution, I ran into the exact same problem. Luckily for me, the solution worked as well. So for those recently running into this problem, give proposed solution a go.
    Note: don't forget to restart for the bcdedit command to take effect.

    Thanks so much for taking the time to post the solution.

+ 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