"box-select" mode

  • Thread starter Thread starter Guest
  • Start date Start date
G

Guest

Hi,

I now understand that:
Application.CommandBars("Drawing").Controls("Select Objects").Execute puts
me into the box-select mode. And running
Application.CommandBars("Drawing").Controls("Select Objects").Execute again
puts me out of box-select mode.

Is there a way to tell if the control("select objects") is currently
selected because sometimes I want to only excute that code if it is not
currently in the box-select mode.

Thanks for you help!
 
Maybe you can use something like:

Dim myCtrl As CommandBarControl
Set myCtrl = Application.CommandBars("Drawing").Controls("Select Objects")
If myCtrl.State = msoButtonUp Then
MsgBox "ready to turn on"
myCtrl.Execute
Else
MsgBox "already clicked"
myCtrl.Execute
End If
 
Back
Top