Excel keeps disabling macros for only one user

sspatriots

Well-known Member
Joined
Nov 22, 2011
Messages
572
Office Version
  1. 365
Platform
  1. Windows
Hi,

We have this one user who can be doing fine in a file that several others use at different times of the day. It has a lot of macros in it to perform different things in the file. He can be in a file and using the buttons or keyboard shortcuts and all of his macros are firing as they should. However, at some point for no apparent reason his macros will not fire any more. So he has to save the file, get out and get back in and then all will start working again as it should, until the next time they stop working while he is in the file. I found the article below that is similar to what he is experiencing, but nobody ever posted a solution to this person's problem easier. Only sharing because I'm hoping someone else may have had to deal with this issue before and might know what to do to fix it.

Excel keeps disabling my macros



Thanks, SS
 

Excel Facts

Which Excel functions can ignore hidden rows?
The SUBTOTAL and AGGREGATE functions ignore hidden rows. AGGREGATE can also exclude error cells and more.
Do have any Worksheet or Workbook event code that exits or errors in-between an Application.EnableEvents = False statement and an Application.EnableEvents = True statement?

but nobody ever posted a solution to this person's problem
Not surprising as the poster never responded to the questions they were asked
 
Last edited:
Upvote 0
Solution
Do have any Worksheet or Workbook event code that exits or errors in-between an Application.EnableEvents = False statement and an Application.EnableEvents = True statement?


Not surprising as the poster never responded to the questions they were asked
There are some events enabled at the end of some code and turned off in the beginning. However, nobody else here is experiencing this problem with that file.
 
Upvote 0
Next time it happens rather than closing the file, run a regular macro enabling the events or in the Immediate Window type Application.EnableEvents=True and press Enter.

Then see if the macro's are running again to determine if that is the issue to start with (the fact it is just the one user it happens to would make me think it is something they are doing rather than a pure code issue, but you need to work out what is exactly happening first)
 
Upvote 0
It sounds like it is being triggered by a certain macro or part of a macro. I would suggest comparing the Security settings for this user's computer with someone who doesn't have the issue.

t0ny84
 
Upvote 0
Next time it happens rather than closing the file, run a regular macro enabling the events or in the Immediate Window type Application.EnableEvents=True and press Enter.

Then see if the macro's are running again to determine if that is the issue to start with (the fact it is just the one user it happens to would make me think it is something they are doing rather than a pure code issue, but you need to work out what is exactly happening first)
When he would try and run a macro nothing would happen. Even saw a pop-Up message that said macros were not enabled.
 
Upvote 0
Next time it happens rather than closing the file, run a regular macro enabling the events or in the Immediate Window type Application.EnableEvents=True and press Enter.

Then see if the macro's are running again to determine if that is the issue to start with (the fact it is just the one user it happens to would make me think it is something they are doing rather than a pure code issue, but you need to work out what is exactly happening first)
Sorry, I just noticed this second response when I came to work this morning. This is a good idea. I'm wondering if his going to another open workbook is triggering something that is disabling his macros in this workbook. I will try this. Thanks, SS
 
Upvote 0
Do have any Worksheet or Workbook event code that exits or errors in-between an Application.EnableEvents = False statement and an Application.EnableEvents = True statement?


Not surprising as the poster never responded to the questions they were asked
I marked this as the solution, because it looks like it was an issue with code in the other workbook, he was opening every day and running code from it with a button to create a report. That code turned off the events when it cleared the existing data to refresh the report. Once I went into the other workbook and set the Enable Events to true at the end of that code in the other workbook, the problems went away. Thanks so much for your help. Sincerely, SS
 
Upvote 0

Forum statistics

Threads
1,215,069
Messages
6,122,959
Members
449,096
Latest member
Anshu121

We've detected that you are using an adblocker.

We have a great community of people providing Excel help here, but the hosting costs are enormous. You can help keep this site running by allowing ads on MrExcel.com.
Allow Ads at MrExcel

Which adblocker are you using?

Disable AdBlock

Follow these easy steps to disable AdBlock

1)Click on the icon in the browser’s toolbar.
2)Click on the icon in the browser’s toolbar.
2)Click on the "Pause on this site" option.
Go back

Disable AdBlock Plus

Follow these easy steps to disable AdBlock Plus

1)Click on the icon in the browser’s toolbar.
2)Click on the toggle to disable it for "mrexcel.com".
Go back

Disable uBlock Origin

Follow these easy steps to disable uBlock Origin

1)Click on the icon in the browser’s toolbar.
2)Click on the "Power" button.
3)Click on the "Refresh" button.
Go back

Disable uBlock

Follow these easy steps to disable uBlock

1)Click on the icon in the browser’s toolbar.
2)Click on the "Power" button.
3)Click on the "Refresh" button.
Go back
Back
Top