Control an Autoshape

G

Guest

Is there a way to assign control events to shapes? You can use action
settings to have a shape do something on mouse click or mouse over, but what
if you want to do something on double-click or any other command button
event?

I have a command button I've assigned a macro that runs on GotFocus event
(because I want to right-click on it and move to a certain slide). I want to
do the same thing on an autoshape.

For the future, I'd also like to double-click on an autoshape and have it do
something (like move to a certiain slide).
 
B

Bill Dilworth

If you are already familiar with VBA and are ok with its limitations, why
not use a real command button instead of an action setting off a autoshape?
If you do, you will have the options of click, double-click, Mouse Down
(which can detect left, right, Shift, Control, or other augmenting mouse
keys).

To insert a real control button, select View => Toolbars => Control Toolbox
then select/insert the Command Button


--
Bill Dilworth
A proud member of the Microsoft PPT MVP Team
Users helping fellow users.
billdilworth.mvps.org
-_-_-_-_-_-_-_-_-_-_-_-_-_-_-_-_-_-_-_-_
yahoo2@ Please read the PowerPoint
yahoo. FAQ pages. They answer most
com of our questions.
www.pptfaq.com
..
..
 
G

Guest

Would that I could, but I need to have this specific shape, which is a
triangle. I cannot figure out how to make a command button be anything but a
rectangle. I tried using and "image" control button, but there's still a
rectangle around the shape. Even if the rectangle is transparent, clicking on
it (and not necessarily the shape) will still cause the action.

So that's my problem. If you can think of any work around, I'm open.
 
B

Bill Dilworth

Something like this will get you the double click, but I'll have to think
about the shift state.

=====Begin Code=====
Dim Time1 As Single

Sub Cliclick()
Dim OldTime As Single

OldTime = Time1
Time1 = Timer

If Abs(Time1 - OldTime) < 0.5 Then
Time1 = 0
MsgBox "Double click"
End If

End Sub
=====End Code=====

--
Bill Dilworth
A proud member of the Microsoft PPT MVP Team
Users helping fellow users.
billdilworth.mvps.org
-_-_-_-_-_-_-_-_-_-_-_-_-_-_-_-_-_-_-_-_
yahoo2@ Please read the PowerPoint
yahoo. FAQ pages. They answer most
com of our questions.
www.pptfaq.com
..
..
 

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

Top