See if cell is in a range

  • Thread starter Thread starter Dan Rositer
  • Start date Start date
D

Dan Rositer

How can I check to see if the ActiveCell is in a give Range?
VBA solution...

Dan
 
Dan

check the Help for Intersect

For example (not tested):

If Intersect(ActiveCell, Range("A1:C20") Is Nothing Then
MsgBox "Not in Range"
Else
MsgBox "In Range"
End If

Regards

Trevor
 

Ask a Question

Want to reply to this thread or ask your own question?

You'll need to choose a username for the site, which only take a couple of moments. After that, you can post your question and our members will help you out.

Ask a Question

Back
Top