SUM() cells by variables
Yup, fer sure -- Version 2 was slicker 'n a pig in poop. Did the job perfectly.
Can't thank you enough! (Something about "job security" <g).
--
Dave
Temping with Staffmark
in Rock Hill, SC
"Norman Jones" wrote:
Hi Dave,
Alternatively, depending on your intended target cell, try:
'=============
Public Sub Tester()
Dim myWorkCell As Range
Dim myCount As Long
Set myWorkCell = Range("A1")
myCount = 5
myWorkCell.Offset(myCount, 17) = _
Application.Sum(myWorkCell(2, 13).Resize(myCount))
End Sub
'<<=============
---
Regards,
Norman
|