VBA Excel macros stopped working

Anonymous
2019-06-30T08:07:55+00:00

I'm getting errors when trying to execute any macro in Excel (won't execute anything, even MsgBox)

Pretty sure it has something to do with Windows Update, Defender, missing/corrupt files, conflict with other files/software/drivers (AcrobatPDF, NVIDIA?), incorrect permissions or disabled services, or anything else?

I tried sfc /scannow and it found some corrupted files and successfully fixed them, also tried uninstalling and reinstalling Office but no luck in getting it fixed

It might be worth mentioning I get BSODs quite often (also CRC errors when unpacking rar/zip files, and issues installing msi/cab/packages etc); not sure if it has anything to do with the VBA not functioning 

How do I diagnose the issue?

Microsoft 365 and Office | Excel | For home | Windows

Locked Question. This question was migrated from the Microsoft Support Community. You can vote on whether it's helpful, but you can't add comments or replies or follow the question.

0 comments No comments
{count} votes

4 answers

Sort by: Most helpful
  1. Andreas Killer 144K Reputation points Volunteer Moderator
    2019-06-30T09:26:14+00:00

    Before I say anything, I would like to see a screenshot.

    Please make a new file

    Open the VBA editor

    Click Tools \ References and make a screenshot from that window and post it here

    Then do as follows:

    Close Excel

    Press and hold the CTRL key

    Open Excel

    Wait for a message to appear and ask for "Safe Mode"

    Release the CTRL key

    Click Yes

    After Excel opens

    Make a new file

    Test the behavior

    Any change in the behavior?

    Andreas.

    0 comments No comments
  2. Anonymous
    2019-06-30T09:39:21+00:00

    Here is the references window

    I just tried safe mode but the issue persists

    The errors I'm getting so far:

    Compile errors

    Error in loading DLL

    Cannot run the macro "_______" The macros may not be available in this workbook or all macros may be disabled

    0 comments No comments
  3. Andreas Killer 144K Reputation points Volunteer Moderator
    2019-06-30T10:50:16+00:00

    There is one reference missing, that means at min. your Office is damaged. You can try to uninstall and reinstall Office as described in this article:

    https://support.office.com/en-us/article/uninst...

    But IMHO the BSODs are a sign that something is fundamental wrong with your PC.

    Therefore, I advise to make a complete backup of your computer right now!

    Then try to repair your Windows as described here:

    https://support.microsoft.com/en-ie/help/402652...

    https://answers.microsoft.com/en-us/windows/for...

    If that doesn't help:

    Maybe it will be necessary to completely reinstall your windows, and furthermore it might be possible that you have a hardware problem (with your motherboard and/or RAM). I suggest that you contact a PC service at your local area and have your PC tested.

    Andreas.

    0 comments No comments
  4. Anonymous
    2019-07-01T14:00:53+00:00

    Ran sfc /scannow 3 times, no errors (Windows Resource Protection did not find any integrity violations)

    Ran memtest to check for RAM issues, all tests passed with no errors

    Ran chkdsk to check for disk issues, no errors

    Office completely uninstalled (manually) including all registry keys and temp files and reinstalled twice, issue persists

    DISM results in Error 2: The system cannot find the file specified at 12.5% (this was predicted as I have the latest Windows update installed 17663.557 which includes files that aren't on the Windows DVD)

    Is my last resort a Windows reset?

    What is the missing reference? I can try adding it manually

    0 comments No comments