format picture with macro

D

David B

I've been using Word97 to copy figures into a Word document. I copied the
figure to the clipboard, opened a new Word document, and ran a macro to set
the page to landscape, then select the figure and make it 7.5x10 inches (full
page size). I created the macro by recording as I did the formatting.

When I try the same procedure with Word2002 or Word2003, I can set the page
to landscape and past the picture, but I can't select the figure to reset its
size while I'm recording the macro. I can do everything I want manually, but
I can't select the figure while the macro recorder is on.

I've gone through all of the help I can find, but haven't found a solution.
I've tried several different PasteSpecial formats in the macro, but that has
made no difference. I've tried to find a macro command to select the figure,
but that hasn't worked, either. Any suggestions? Thanks.

David
 
J

Jezebel

Most likely the difference between your Word97 and later versions, is the
default graphic mode: on your 97 machine you were, by default, pasting
graphics as inline with text -- in which case you can select the graphic
with the keyboard. On your later machines the default has been set to paste
as floating; in which case you can select only with the mouse, which you
can't do while recording a macro.

However, if this is the only graphic in the document, in VBA you can refer
to the graphic as ActiveDocument.Shapes(1) and set the properties of that
object.

The macro recorder is not intended for creating serious macros: use it only
for keystroke sequences and as a starting point for creating raw code.
 

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