PDA

View Full Version : [SOLVED] Autofit Text to Placeholder



Paul_Hossler
08-09-2007, 07:19 PM
Can any one tell me the VBA to get to the 'Autofit Text to Placeholder'?

If the text is too much for a placeholder, sometimes it will overflow, but PP2003 (XP SP2) put a little control called "Autofit Options" at the lower left, and I can shrink the text to automagically fit into the place holder.

Recording a macro doesn't capture anything:banghead:

There are some AutoCorrect options that have "Autoformat As You Type" check boxes that deal with autofit, but I don't see how to use them.

Any help appreciated:beerchug:

Paul

John Wilson
08-10-2007, 12:01 AM
Hi Paul

This setting is stored in the registry so you would have to write code to modify (not that simple in vba!) It apply to the application not to individual placeholders.

Key is at (for 2003)

HKEY_CURRENT_USER\Software\Microsoft\Office\11.0\PowerPoint\Options\AutoFit TextBody

Paul_Hossler
08-10-2007, 08:33 AM
Thanks, but I was trying to improve my "cleanup" macro so that any place holders that had over-flowing text would get "auto-fitted".

I believe that your registry suggestion sounds like it would turn off the check box in autoformat options.

I was trying to figure out how to call the "autofit" method (if any) to make the text fit.

Did some Google-research and it seems like that's a Smart Tag. Sinking feeling that I won't be able to get to it.

Paul

John Wilson
08-10-2007, 08:52 AM
The reg key will turn it on or off (value 1 =on, 0=off). If you would like vba code to write to this key at your own risk you can email me , I don't want to post it publically because in the wrong hands ....

john AT SIGN technologytrish.co.uk

Paul_Hossler
08-10-2007, 12:20 PM
John, thanks for the reply -- before I take my life in my hands and mess with the registry, will turning it on or off force any existing overflowing text to autofit?

I did a quick PPT test with overflowing text, and went to Tools, Autocorrect Options, Autoformat as you type, and Cleared the Autofit checkboxes, exited, re-set then checks, exited.

Did not force an autofit.

Does the reg key force it to autofit existing overflow?

Paul

John Wilson
08-10-2007, 01:36 PM
Paul

Modifying the registry should do exactly the same as changing the options in powerpoint so I guess the answer is probably NO Existing overflow will not be resized.

Paul_Hossler
08-10-2007, 02:59 PM
Darn

Nothing is ever easy

Thanks

Paul