View Single Post
  #2   Report Post  
Posted to microsoft.public.excel.programming
Otto Moehrbach Otto Moehrbach is offline
external usenet poster
 
Posts: 1,090
Default Worksheetfunction help

Glen
You can't just put in a range address like you can when you use the Sum
formula in a worksheet. You must state that this is a range. Something
like:
newval = Application.WorksheetFunction.Sum(Range("ah" & sRow & ":DD" &
sRow))
HTH Otto
"Glen Mettler" wrote in message
...
This gives me an error. What have I done wrong?
sRow=6
newval = Application.WorksheetFunction.Sum("ah" & sRow & ":DD" & sRow)

Glen