I have read all the threads on this issue but my situation seems a little different so I thought I would post it.
I have 4 macros (call them A,B,C,D). They were all running fine. Recently I started getting the Code Execution message. All the messages were pointing to ghost breakpoints that I had previously used during testing. I tried all the recommended methods to fix the problem but nothing worked. So this is what I found.
I have 4 different versions of a database on my desktop (call them (1,2,3,4). Database 1 only contains macro A. The other 3 databases contain all 4 macros. When I was investigating the problem, I never had more than 1 database open at a time. When I was testing 2,3,4 I would get the Code Execution message and F5 would allow me to continue. However, when I tested db 1 (which I hadn't touched for weeks) I got the Code Execution message but when I pressed F5 I got a message that said the action couldn't be completed because the sheet was protected. I unprotected the sheet in 1 (sheets were not protected in db 2,3,4) and wala all the problems went away and everything runs fine in all the db.
So every thing is fine now but maybe somebody can explain why to me.
I have 4 macros (call them A,B,C,D). They were all running fine. Recently I started getting the Code Execution message. All the messages were pointing to ghost breakpoints that I had previously used during testing. I tried all the recommended methods to fix the problem but nothing worked. So this is what I found.
I have 4 different versions of a database on my desktop (call them (1,2,3,4). Database 1 only contains macro A. The other 3 databases contain all 4 macros. When I was investigating the problem, I never had more than 1 database open at a time. When I was testing 2,3,4 I would get the Code Execution message and F5 would allow me to continue. However, when I tested db 1 (which I hadn't touched for weeks) I got the Code Execution message but when I pressed F5 I got a message that said the action couldn't be completed because the sheet was protected. I unprotected the sheet in 1 (sheets were not protected in db 2,3,4) and wala all the problems went away and everything runs fine in all the db.
So every thing is fine now but maybe somebody can explain why to me.