Quantcast
Channel: Active questions tagged excel - Stack Overflow
Viewing all articles
Browse latest Browse all 88087

Excel crashing trying to set Activesheet.EnableCalculation = true

$
0
0

I have Excel 2016 64 bit on Windows 10. Excel keeps crashing when I try to set a worksheet to enable calculation like this:

ActiveSheet.EnableCalculation = True

So I wrote a test routine to try to capture the error description, but it would not go to the error handler, it just crash, so I cannot even get any detail. The worksheet has a lot of formulae and it is unlock. I also unlock other tabs where the formulae are sourcing the data in their calculation. But it still would not let me set to true as the above line. Any thoughts? Much appreciated.

Sub test2()

   On Error GoTo Detail
   Debug.Print ActiveSheet.EnableCalculation  'this would tell me the current state, it is False.
   ActiveSheet.EnableCalculation = True       'at this line, it crashes

   Exit Sub

Detail:
   Debug.Print Err.Number
   Debug.Print Err.Description

End Sub

~G


Viewing all articles
Browse latest Browse all 88087

Trending Articles



<script src="https://jsc.adskeeper.com/r/s/rssing.com.1596347.js" async> </script>