How can check "lock Picture aspect ratio" option in PowerPoint 200

T

Team

How can I check the "lock Picture aspect ratio" option in PowerPoint 2003
programmatically?
-----------------------------------
I have created a single slide presentation and insert a picture on the slide
by doing the following:
1. Insert a Shape
2. Slect the shape -> Right Click -> Format AutoShape -> Colors and Lines
-> Fill: Fill Effects -> Picture -> Select Picture: Select an image from
folder and click the insert button. After clicking the insert button there is
an option to check -"Lock Picture Aspect Ratio". Is there any way to check
the "Lock Picture Aspect Ratio" programmatically by using the PowerPoint
object model?
 
J

John Wilson

Assuming the pic is selected

ActiveWindow.Selection.ShapeRange(1).LockAspectRatio = msoTrue
 
T

Team

Thanks for the reply.

The below code only checks the option "Lock Aspect ratio"(Select the
shape->Right Click->Format AutoShape->Size->Lock Aspect ratio). But I need to
check the option "Lock Picture Aspect Ratio"( Slect the shape -> Right Click
-> Format AutoShape -> Colors and Lines -> Fill: Fill Effects -> Picture ->
Select Picture: Select an image from folder and click the insert button.
After clicking the insert button there is an option to check -"Lock Picture
Aspect Ratio").
 

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