Tek-Tips is the largest IT community on the Internet today!

Members share and learn making Tek-Tips Forums the best source of peer-reviewed technical information on the Internet!

  • Congratulations Mike Lewis on being selected by the Tek-Tips community for having the most helpful posts in the forums last week. Way to Go!

Excel Application.Calculation prob

Status
Not open for further replies.
Mar 25, 2003
34
0
0
GB
Hi all,

I've got numerous workbooks made up from the same template workbook.

On the Workbooks_Activate event there's a line:
Application.Calculation = xlCalculationAutomatic

Which works fine on some workbooks, but on some i get a critical error, asking me to send report to MS & recover etc.

I'm using XP, XP developer, but I've tried on 2000 & 2003 with same problem. Any ideas?????
 
Actually pressing f9 (calc) causes the same error so it's not nec. vba related ... but still any ideas why this is happening?
 
If you get the error with F9, then as you say it is not directly VBA related. The fact that you are using templates is an indication that the sheets/code that you are using may have become corrupt. I have had this problem myself and although there is probably a technical solution to the problem, what I do to cure it is to Clone the Workbook sheet by sheet to a new book using WINDOW > ARRANGE > TILED and then cloning each sheet by left-clicking on each sheet,waiting for the sheet icon and the holding down Ctrl until the + sign appears. You can then move a clone of the sheet to your new empty sheet. Then export all VBA modules and re-import them into the new sheet. Sounds difficult but doesn't take long.
 
Status
Not open for further replies.

Part and Inventory Search

Sponsor

Back
Top