Hi
change it to
Dim range1 as range
set range1 = worksheets(cstr(WS)).range("B91:B" & g)
MsgBox Application.WorksheetFunction.Sum(Range1)
--
Regards
Frank Kabel
Frankfurt, Germany
Spammastergrand wrote:
WS is a variable not a sheet name. I don;t want to hard code the
sheet name since they'll be working with various months like Jan Feb,
etc