Counting Rows

B

Buster

I tried to create a function to count rows used on a
worksheet and recieved an Overflow(Error 6) message.

Public Function UsedRange()
Dim MyRowCount As Integer
MyRowCount = Sheets("RWI").UsedRange.Rows.Count

End Function

Any ideas on why this message appears. Thanks in advance.

Best, Buster
 
Top