ExcelBanter

ExcelBanter (https://www.excelbanter.com/)
-   Excel Discussion (Misc queries) (https://www.excelbanter.com/excel-discussion-misc-queries/)
-   -   Automatic Calucalation Default (https://www.excelbanter.com/excel-discussion-misc-queries/18312-automatic-calucalation-default.html)

Brandon

Automatic Calucalation Default
 
I've read the previous threads regarding the default calculation setting
returning to "Manual" I do use personal.xls for storing macros and suspcet
this is related. The expert advice was to open Personal.xls to start the
excel session and change the calculation setting to automatic.
Unfortunately, personal.xls does not have a worsheet associated with it,
therefore "options" is not available on the tools menu. Please advise.

Dave Peterson

You could add a workbook, change the calculation.

But if you close that temporary workbook, I think (I don't recall for sure) that
excel will pick up the calculation mode from the next workbook opened.

Option Explicit
Sub auto_open()

Dim wkbk As Workbook

Set wkbk = Workbooks.Add
Application.Calculation = xlCalculationAutomatic
'wkbk.close savechanges:=false

End Sub

If you feel like experimenting, uncomment that .close line and open a workbook
that was saved with calculation set to manual.

If xl changes calculation mode back to manual, then don't use that "wkbk.close"
line

Brandon wrote:

I've read the previous threads regarding the default calculation setting
returning to "Manual" I do use personal.xls for storing macros and suspcet
this is related. The expert advice was to open Personal.xls to start the
excel session and change the calculation setting to automatic.
Unfortunately, personal.xls does not have a worsheet associated with it,
therefore "options" is not available on the tools menu. Please advise.


--

Dave Peterson

Dave Peterson

I just tested. If you close that workbook (and there is no activeworkbook, then
excel may change the calculation mode.

And I think I like this just a bit better.

Option Explicit
Sub auto_open()

Dim wkbk As Workbook
If ActiveWorkbook Is Nothing Then
Set wkbk = Workbooks.Add
Else
'do nothing
End If

Application.Calculation = xlCalculationAutomatic

End Sub


It just checks to see if it HAS to add another workbook first.

Dave Peterson wrote:

You could add a workbook, change the calculation.

But if you close that temporary workbook, I think (I don't recall for sure) that
excel will pick up the calculation mode from the next workbook opened.

Option Explicit
Sub auto_open()

Dim wkbk As Workbook

Set wkbk = Workbooks.Add
Application.Calculation = xlCalculationAutomatic
'wkbk.close savechanges:=false

End Sub

If you feel like experimenting, uncomment that .close line and open a workbook
that was saved with calculation set to manual.

If xl changes calculation mode back to manual, then don't use that "wkbk.close"
line

Brandon wrote:

I've read the previous threads regarding the default calculation setting
returning to "Manual" I do use personal.xls for storing macros and suspcet
this is related. The expert advice was to open Personal.xls to start the
excel session and change the calculation setting to automatic.
Unfortunately, personal.xls does not have a worsheet associated with it,
therefore "options" is not available on the tools menu. Please advise.


--

Dave Peterson


--

Dave Peterson

Gord Dibben

Brandon

Personal.xls is open and hidden.

Just go to WindowUnhide and select Personal.xls.

With it open, make your settings change then hide again and save.


Gord Dibben Excel MVP

On Fri, 18 Mar 2005 12:49:04 -0800, "Brandon"
wrote:

I've read the previous threads regarding the default calculation setting
returning to "Manual" I do use personal.xls for storing macros and suspcet
this is related. The expert advice was to open Personal.xls to start the
excel session and change the calculation setting to automatic.
Unfortunately, personal.xls does not have a worsheet associated with it,
therefore "options" is not available on the tools menu. Please advise.




All times are GMT +1. The time now is 05:50 PM.

Powered by vBulletin® Copyright ©2000 - 2025, Jelsoft Enterprises Ltd.
ExcelBanter.com