[lnkForumImage]
TotalShareware - Download Free Software

Confronta i prezzi di migliaia di prodotti.
Asp Forum
 Home | Login | Register | Search 


 

Forums >

microsoft.public.excel.programming

Re: How to know if a range has been selected

Dave Peterson

12/13/2006 5:48:00 PM

Like the difference between selecting a range or an object (chart/button/...)??

If TypeName(Selection) = "Range" Then
MsgBox "it's a range!"
Else
MsgBox "it's not a range...it's a: " & TypeName(Selection)
End If



Maria wrote:
>
> I'm fairly new to excel vba. Can someone tell me how to determine if a range
> has been selected on a worksheet? If a selection has not been made, I need
> to display a message to the end user.
>
> --
> Regards.

--

Dave Peterson