I'd like a little help in setting up a reusable routine. In tons of my macros I check for the entire column or row to avoid long processing times. My preferred method is below (feel free to comment if there's a better way). My question/need is to have this routine in it's own procedure and to call it from my macros instead of replicating the code over and over. Any help is appreciated.
'Check for Rangesize
If Selection.Columns.Count = ActiveSheet.Columns.Count Or Selection.Rows.Count = ActiveSheet.Rows.Count Then
MsgBox "You've selected an entire Row or Column." & vbCrLf & _
"Please select a smaller range to check.", vbCritical, "Range Too Large to Process"
Exit Sub
End If
Bookmarks