Macros not working

angel34

Board Regular
Joined
Jun 3, 2016
Messages
79
I migrated last week from a computer running Office 2007 on Windows 7 to a new computer running Office Professional 2010 plus on Windows 10. I am facing a weird problem since then. None of my macros seem to work on my new computer. My macros are all proven and have worked flawlessly for years.

I tried he following in order to solve the problem with no luck.

1. Enabled macros from Macro Security-->Macro Settings-->Disable all macros with notification so that they can be enabled when the workbook opens.

2. To rule out incompatibility issues, I have saved all workbooks containing macros in .xlsm format in Office 2010.

3. Macros created are all workbook specific hence stored in the respective workbooks and not in a Personal Macro Workbook). Hence, I guess, I could not find a .xlsb file in the XLStart folder (C/Users/Username/AppData/Roaming/Microsoft/Excel/XLStart). I thought of copying it in the XLStart folder of my new computer.

I do not know of any other measure that I could take at this moment so that the macros start working again.

I am at my wits end what to do about this problem further and is completely clueless about how to recover my macros since they are quite large in number and I do not have the time to recreate them. I shall be extremely thankful if somebody kindly guide me figure out the solution.
 
Well, without seeing your code and/or having access to your system, I am afraid that there probably isn't much more assistance I can offer.

I would recommend adding a break-point to the Message Box we just added, and try running the code again. Then, it should stop at this line of code.
You can then proceed through your code line-by-line using the F8 key to see exactly what is going on.
If you do this while watching what happens on your sheets, many times the problem will reveal itself.
Yes Sir. I appreciate. I will do what you advised and revert back. Thank you for your help and the valuable time you spent in replying to my query.
 
Upvote 0

Excel Facts

What is =ROMAN(40) in Excel?
The Roman numeral for 40 is XL. Bill "MrExcel" Jelen's 40th book was called MrExcel XL.
You are welcome.
Good luck!
 
Upvote 0
I tried to debug my code by stepping into it in vba editor. But the process doesn't advance beyond line 1, Macro is running. Do you think uninstalling and reinstalling Office might be a solution? But again I noticed that the code I type on the vba editor, works perfectly. The problem is just with the code I copied from the other computer.
 
Upvote 0
I tried to debug my code by stepping into it in vba editor. But the process doesn't advance beyond line 1, Macro is running.
When you add a break point, it will stop at that point. You then manually advance through the code one line at a time by pressing the F8 key repeatedly.
Are you saying that when you press the F8, it does not move off of the line with the breakpoint?
 
Upvote 0
Yes Sir. That is precisely what is happening. When I press F8 at the breakpoint, nothing happens. The debugger doesn't move to the next line of the code. Is it possible that the files got corrupted either while transferring or while storing it in a external hard drive before being copied?
 
Last edited:
Upvote 0
Corruption sounds like a good possibility.
 
Upvote 0
Yes Sir. That is precisely what is happening. When I press F8 at the breakpoint, nothing happens. The debugger doesn't move to the next line of the code. Is it possible that the files got corrupted either while transferring or while storing it in a external hard drive before being copied?
Have you found a solution for this? I have a similar problem with my files with multiple macros and are currently not working with no error message since my migration to another PC. If such file is indead corrupted, as @Joe4 has mentioned, then the file should not work in other PCs, right? But when I tried it in my colleagues' PCs, it works just fine.
 
Upvote 0
Have you found a solution for this? I have a similar problem with my files with multiple macros and are currently not working with no error message since my migration to another PC. If such file is indead corrupted, as @Joe4 has mentioned, then the file should not work in other PCs, right? But when I tried it in my colleagues' PCs, it works just fine.
If they work on other computers, I would doubt your file is corrupted. It is most likely same settings on that one computer.
Are you sure that you have enabled Macros/VBA on that one computer that they are not working on?
 
Upvote 0
If they work on other computers, I would doubt your file is corrupted. It is most likely same settings on that one computer.
Are you sure that you have enabled Macros/VBA on that one computer that they are not working on?
Yes, Macros Settings is set to "Disable with notifications", and everytime I open an Excel file with macros, I enable said macros. To add, macros that I create on my PC are working on my PC and others, while macros created from other PCs does not work on my PC.
 
Upvote 0
Are you sure that the files aren't blocked by Windows? if you are transferring them from the other other computers via email, shared server or via the net then they probably are.

Easiest way to check is to right click the file - click properties - click the General tab and look near the bottom and see if you have an Unblock box as below in the image. If you do then check the box and click OK.

1673416409493.png
 
Last edited:
Upvote 0

Forum statistics

Threads
1,215,046
Messages
6,122,854
Members
449,096
Latest member
Erald

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