• Hi All

    Please note that at the Chandoo.org Forums there is Zero Tolerance to Spam

    Post Spam and you Will Be Deleted as a User

    Hui...

  • When starting a new post, to receive a quicker and more targeted answer, Please include a sample file in the initial post.

Excel 2010 shutdown

Villalobos

Active Member
Hello,

I have a file (the size is around 900 Kb) which has been created by Excel 2013 (there are some macro codes in) and when I use it in this version there are not any kind of problem, but if I open it in Excel 2010 in my office (the codes are running normally) and want to "Save" or "Save as" it the Excel is shuts down constantly.

May be one of command is not compatible with the version 2010 or anything else?

These are the primary commands which are in the file:
Code:
Private Sub Worksheet_SelectionChange(ByVal Target As Excel.Range)
End Sub

PivotTables("Table1").RefreshTable

Private Sub Workbook_BeforePrint(Cancel As Boolean)
End sub

Private Sub Workbook_NewSheet(ByVal Sh As Object)
End Sub

Private Sub MonthView1_DateClick(ByVal DateClicked As Date)
End Sub

Private Sub UserForm_Initialize()
End Sub

Private Sub cmdClose_Click()
End Sub

Private Sub UserForm_QueryClose(Cancel As Integer, CloseMode As Integer)
End Sub

Private Sub CheckAll()
End Sub

Private Sub TextBox_KeyPress(ByVal KeyAscii As MSForms.ReturnInteger)
End Sub

Private Sub UserForm_Terminate()
End Sub

In addition there are 2 pivotcharts (without slicers), 5 normal charts and some normal and array formulas.

Do you have any idea why shuts down?
 
Those all look like standard commands, which I can see in my Office 2010. There's no "Workbook_BeforeSave" event by chance, is there?
 
No, there is not.
I tried in version 2007 also and everything is working fine as in version 2013. The problem is only with 2010, I can not save the file.
 
Strange. Do you get a save dialogue or anything to appear, or as soon as you hit save, it closes?
Trying debugging approach
Tried various save methods:
  • Hit Save button on Ribbon
  • Hit Ctrl+S on keyboard
  • Use SaveAs from Ribbon
  • Hit F12 to do a SaveAs

any of the above options create different results?
 
The duration of closing procedure it takes ~30 seconds, during this period there is a dialogue panel (the backcolor of screen is light grey) in the middle of screen with following text: Excel is shutdown. As closed the workbook the Excel automatically try to open again the file as "repaired" but if I want to save the "repaired" workbook shutdown again.

I did not tested your keyboard shortcut idea even, tomorrow I will be in the office and will try it and come back to you result.
 
The other idea is that saving typically invokes a recalculation to occur, and during the recalculation, some formula (???) is causing a application crash. I've never actually seen that happen, so this is confusing. :eek::confused:
 
I tried various save methods, but nothing happened. But... Based on your "recalculation" idea I canceled the calculation sheet (where I store the all formulaes) and after I can save it as I just want. So it seems to me one of formulae cause this problem (ughh... I am bit closer to solve the problem; finally I can localize the area of problem), I have to check one by one formulaes.

May be do you know a simplier method (any kind of Excel settings) to detect which formulae could cause a problem for the "Save" process?
 
Under Formula, Formula Auditing, you might try hitting the Error checking button. Not sure it will help in this case, but might be a start.
Other than that, can't think of anything fancy. Just try disable/deleting groups of formulas at a time, until you isolate which one is causing a problem. :(
 
I think I found (to tell the truth I really hope that) the root of problem. The problem was not in the formulaes, there were 2 pivots beside each other (only two blank columns separated them), I just moved one of them to another cell and now the "Save" and "Save as" functions running well the other functions (macros, array and formulaes) are working normally as well.

I'll make some tests.
 
Last edited:
Back
Top