I have some code that performs a number of operations on some excels, saves them and moves them to a new folder. I have some currently that are crashing Excel on the Workbook.Save command. I turned on Alerts and created an error trap but Excel just crashes. How can I figure out what is going on?
Code:
If processed = True And e = 0 Then Application.DisplayAlerts = False
Wb.RemovePersonalInformation = True 'double clean
fileName = Wb.Name
On Error Resume Next
Err.Clear
[B] Wb.Save 'save it[/B]
e = Err.Number
If e <> 0 Then GoTo saveFile
On Error GoTo saveFile
Wb.Close 'close it
Call moveCurrentFile(fileName, inProcessingPath, processedPath) 'move it
Application.DisplayAlerts = True