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

Totaling a Range of Data

Status
Not open for further replies.

dak413

Technical User
Oct 31, 2005
3
US
I am a beginner user to Visual Basic and am having trouble obtaining a total for a range of data in a single column where the number of rows will changes each time the macro is run? The only formula I can find is for a fixed range:

ActiveCell.FormulaR1C1 = "=SUM(R[-19]C:R[-1]C)"

What would be the alternative to this so that it doesn't have a fixed range to total?
 
Have a look in the FAQ area: at least two ways to retrieve the last used row of a range.

Hope This Helps, PH.
Want to get great answers to your Tek-Tips questions? Have a look at FAQ219-2884 or FAQ181-2886
 
Status
Not open for further replies.

Part and Inventory Search

Sponsor

Back
Top