Hello Mudraker,
Thanks, FYI, this part of the code
Cells(r, "c").FormulaR1C1 = "=sum(c1:c" & r - 1 & ")"
didn't work property but I figured out and fixed it.
Here's what I came with and works fine:
Cells(r, "c").Value = "=sum(c1:c" & r - 1 & ")"
Thanks for your great help and also all of the rest of you
who provided me with options.
Juan
-----Original Message-----
Sub ss()
Dim r As Long
r = Cells.Find(what:="*", SearchOrder:=xlByRows, _
SearchDirection:=xlPrevious).Row + 1
' format range as required
'Range("a" & r & ":o" & r).Select
'Selection.Font.Bold = True
Range("a" & r & ":o" & r).Font.Bold = True
Cells(r, "a").Value = "Total"
Cells(r, "c").FormulaR1C1 = "=sum(c1:c" & r - 1 & ")"
End Sub
---
Message posted from http://www.ExcelForum.com/
.