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 John Tel on being selected by the Tek-Tips community for having the most helpful posts in the forums last week. Way to Go!

VBA Application.Calculate 2

Status
Not open for further replies.

WaterSprite

Technical User
Mar 23, 2004
69
US
I am using:

.Range(cells(11, 11), Cells(19, 11).Application.Calculate

That works out to be about 9 cells.
Why is it taking almost 3 minutes to calculate the spreadsheet.


 
As you use the Calculate method of the Application object you calculate ALL the open workbooks.
You wanted this ?
.Range(.Cells(11, 11), .Cells(19, 11).Calculate

Hope This Helps, PH.
Want to get great answers to your Tek-Tips questions? Have a look at FAQ219-2884 or FAQ181-2886
 
Depends how your data and formulas are sturctured. If there are any cell dependencies associated with those cells, then it will have to update their heirarchy as well.

Look at these different calculation methods ...

Code:
Sub testAppCalc()
    Range("A1").Calculate
    Stop
    ActiveSheet.Calculate
    Stop
    Application.Calculate
    Stop
    Application.CalculateFull
    Stop
    Application.CalculateFullRebuild
End Sub

I suggest you check out Charles Williams site...


HTH

Regards,
Zack Barresse

Simplicity is the ultimate sophistication. What is a MS MVP? PODA
- Leonardo da Vinci
 
Thanks. Did not know I could use .calculate. Thought it always had to be application.calculate.
 
Status
Not open for further replies.

Part and Inventory Search

Sponsor

Back
Top