You mention also that you want this to happen with objects that you've created, rather than with a
scrollbar. That's not the same problem, so of course the answer won't work.
Suppose we start over ... please describe exactly what you want to do here.
Normal spelling and punctuation would be helpful too. VBA won't let you use shorthand; may as well
get into practice by avoiding it here too. Easier to understand.
Thanks.
Good Idea.
Alright, So I have one long rectangle and objects above and below it. As I
click left, the objects and rectangle should move left and vice versa. I have
the long rectangle increase in size and change positions as effects at the
beginning of the slide. Then the other objects around the long rectangle zoom
in. As the same time all this zooms in, the Left and Right control buttons
zoom in. After all this, I want to move all these object left and right from
the position the effects place them in. Alright, I think I got everything. Is
there anything you still want me to clear up?
> You mention also that you want this to happen with objects that you've created, rather than with a
> scrollbar. That's not the same problem, so of course the answer won't work.
[quoted text clipped - 90 lines]
> PPTools: www.pptools.com
> ================================================
Steve Rindsberg - 07 Sep 2007 03:42 GMT
> Good Idea.
> Alright, So I have one long rectangle and objects above and below it. As I
[quoted text clipped - 5 lines]
> the position the effects place them in. Alright, I think I got everything. Is
> there anything you still want me to clear up?
OK, the animation stuff isn't relevant to the VBA, is it?
Hey, I asked for thorough, you gave me thorough ... I'm not complaining! <g>
For starters, you'll want to make two rectangles rather than one, if you want to distinguish between
clicks on one side and the other.
Let's call the left one Decrease and the right one Increase
Add this macro to your project and make the Increase rectangle's action setting Run Macro: Increase
Sub Increase()
Dim IncrementAmount as Single
IncrementAmount = 10 ' but change it to what you want
ActivePresentation.Slides(1).Shapes("Rectangle 3").IncrementLeft (IncrementAmount)
End Sub
Do the same with the decrease rectangle only make it run this
Sub Decrease()
Dim IncrementAmount as Single
IncrementAmount = 10 ' but change it to what you want
ActivePresentation.Slides(1).Shapes("Rectangle 3").IncrementLeft (-IncrementAmount)
End Sub
In both of the above:
Change the .Slides(1) to .Slides(x) where x = the number of the slide this all happens on.
Change "Rectangle 3" to whatever the name of the shape is.
To move more shapes, duplicate the same line and change the name of the shape as needed.
-----------------------------------------
Steve Rindsberg, PPT MVP
PPT FAQ: www.pptfaq.com
PPTools: www.pptools.com
================================================