Final VBA command to rename, change file type and save will not run

Gordon32114

New Member
Joined
Apr 21, 2015
Messages
3
I have had an ongoing issue with Excel that I hope someone might be able to help me with.

Each month I am tasked with parsing out reports for our clients from one main Excel file (the file contains VBA code which runs later in the process). I have a batch file that copies the main file into multiple files renamed with the individual customer names.

I am then to open the individual files and the VBA code takes over upon opening. The VBA code breaks out and deletes any line items that don’t match the file name so I am left with only data pertinent to each client.

When I perform this task the VBA runs correctly until it reaches the line instructing it to rename the file / change from a .XLSM to .XLSX format and save the file to my departments network folder.

When it reaches this final step it just stops. In order to complete the process I have been manually renaming the files and saving in an “.XLSX” format.

When others on my team open these same files they run correctly, I am the only one having an issue so it’s not the VBA code.

Yesterday a coworker and I discovered that if I manually walk down through the VBA using the “F8” button the code actually works. It performs the final task of renaming, changing the type and saving to the network folder.

We have compared my Excel settings to that of my coworker and are unable to find where anything is different. Does anyone have an idea of why this might be happening? I would think it almost has to be a setting on my laptop somewhere.

Thanks for any suggestions.
 

Excel Facts

How to total the visible cells?
From the first blank cell below a filtered data set, press Alt+=. Instead of SUM, you will get SUBTOTAL(9,)

rlv01

Well-known Member
Joined
May 16, 2017
Messages
991
Office Version
  1. 365
  2. 2010
Platform
  1. Windows
Google "vba phantom breakpoint" and see if it fits your symptoms.
 

Logit

Well-known Member
Joined
Aug 31, 2016
Messages
4,150
Another approach might be to retype that portion of the macro you are referring to.

I have found that Excel will, for an unknown reason, corrupt macro code for no reason ... and there is no way of telling it is corrupted simply by looking at it.

My 2 cents.
 

Forum statistics

Threads
1,141,405
Messages
5,706,264
Members
421,437
Latest member
GijoeBlack

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
Top