I've read the "help" and as far my competence reaches, there's no errors in this code. VBA refuses to agree and usually, it's right. What's wrong here?
[vba]
Sub DoStuff()
Dim sel As Range
Set sel = Selection
DoStuffToRange (sel) ' here VBA claims is an 424-error
End Sub
Sub DoStuffToRange(ByRef r As Range)
For Each c In r
MsgBox c.Value
Next c
End Sub
[/vba]
I also tried Selection.Cells (the same error) and Selection.Range (different error).