How to get the left and top position of any shape or image inserte

A

Abhishek Bagga

I need to get the left and top of the image or shape inserted within a
powerpoint slide.
At present i am using shape.Left adn Shape.Top but this actually is not the
left and top of the shape but the movement from its previous position
It works fine if the shape is not moved after inserting, but if it is moved
left or right, top or bottom it gives the distance moved from the previous
position.
 
S

Steve Rindsberg

Abhishek Bagga said:
I need to get the left and top of the image or shape inserted within a
powerpoint slide.
At present i am using shape.Left adn Shape.Top but this actually is not the
left and top of the shape but the movement from its previous position
It works fine if the shape is not moved after inserting, but if it is moved
left or right, top or bottom it gives the distance moved from the previous
position.

Can you post some code that demonstrates this? .Left and .Top give the current
values of each of those properties. Of course, if the shape's been moved, the
properties will have changed, but neither gives the amount of change, just the
absolute value.



--
Steve Rindsberg, PPT MVP
PPT FAQ: www.pptfaq.com
PPTools: www.pptools.com
================================================
Apologies for the delayed response.
Just back from PowerPoint Live 2004
Had a great time, learned a lot
================================================
 
C

Chris

Ar you use "ActivePresentation.Slades(1).Shapes("name of your shapes").Left"?
If you dont know the name of the Shape use the number insted "Shapes(1)"
For me it works, I get the exact position and not the distance from previous.
You can save the previous position by use
Dim oLeft as Shape
oLeft = ActivePresentation.Slades(1).Shapes("name of your shapes").Left
But that you probebly alredy know ; )
 

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