Calculating Selected Cells

N

NlCO

Hi, I need a little help here, I'm working in a "heavy" spreadsheet that
has hundredrs of arrays, lots of macros and other staff.

In my macros I used Activesheet.Calculate so it does'nt calculate the
whole workbook everytime.

Also I've pase all the possible values to make the file "lighter", but
what I can't do is make it work faster, sometimes I've change just one
formula and I have to calculate the whole sheet (SHIFT+F9) to get the
result (I've disabled the automatic calculation)
Is there any way to calculate just one cell or a group of them?

Thanks

NlCO
 
D

dominicb

Good morning Nico

Highlight a portion of your spreadsheet and then run the code below.
This should recalculate only the highlighted section of your sheet.

Sub Recalc()
ActiveWindow.RangeSelection.Calculate
End Sub

HTH

DominicB
 
N

NlCO

Thank You Dominic, I tried your solution but it didn't worked, I receiv
a message saying:

Ambiguous Name Detected: Recalc

But through that error I finally found the answer:

Worksheets("Sheet1").UsedRange.Range("E30:E56,G30:G56").Calculate

Thanks a lot

Nico :) :
 

Ask a Question

Want to reply to this thread or ask your own question?

You'll need to choose a username for the site, which only take a couple of moments. After that, you can post your question and our members will help you out.

Ask a Question

Top