Share via

using graphic with MACROBUTTON

Anonymous
2011-12-20T16:26:01+00:00

in prior version of WORD, this was the method to use a graphic with MACROBUTTON:

  1. Copy the graphic you intend to use as the button to the Clipboard. (You could do this by temporarily placing the graphic somewhere in your document and Cutting it to the Clipboard.)
  2. Create a MACROBUTTON field.
  3. Place the insertion point in the MACROBUTTON field where the buttonText instruction should appear.
  4. On the Edit menu, choose Paste Special and select Picture to insert the graphic as the button.

I've tried this repeatedly in Word 2010 and all I have is the graphic ... no action.

Can anyone tell me how to run a marco within the text of a document from a graphic?  I do not want a toolbar/ribbon button.  I am needing a button on the document itself.

Thanks for any suggestions ... especially those that work!

Janie

Microsoft 365 and Office | Word | For home | Windows

Locked Question. This question was migrated from the Microsoft Support Community. You can vote on whether it's helpful, but you can't add comments or replies or follow the question.

0 comments No comments

Answer accepted by question author

Charles Kenyon 167.7K Reputation points Volunteer Moderator
2011-12-20T18:46:17+00:00

I tried as well. Same result. I then saved the document in legacy format (.doc) and the macrobutton works.

It Word 2010 (docx) format all that happens is the picture is selected and you get picture editing tools.  Bottom line: To have the macrobutton work with a graphic, you must be in .doc (.dot) format.

Sort of like legacy WordArt, I guess. Except with WordArt if I create WordArt using the legacy gallery in a .doc formatted document and then convert that document to Word 2010, my Word Art stays. With the macrobutton, it reverts to not working.

Additional note:

I made my macrobutton prompt as follows:

prompt [graphic] prompt

That is the word prompt surrounded the inline graphic. In the .doc format, you could see the word "prompt" on each side of the graphic. In the .docx format, the first word "prompt" is occulted by the graphic which is followed by an equivalent amount of space before the second word "prompt" appears.

Was this answer helpful?

0 comments No comments

6 additional answers

Sort by: Most helpful
  1. Anonymous
    2011-12-20T19:30:02+00:00

    You could use the OnEntry event of Picture content control.  It might be awkward as the event would fire immediately (not on dbl-click) when the user clicked the CC.

    Was this answer helpful?

    0 comments No comments
  2. Anonymous
    2011-12-20T19:23:24+00:00

    how disappointing!  I'll save down to the "doc" version.  I do so wish Microsoft would quit "improving" things!

    Thanks to all who gave suggestions.

    Was this answer helpful?

    0 comments No comments
  3. Charles Kenyon 167.7K Reputation points Volunteer Moderator
    2011-12-20T18:57:36+00:00

    Thanks for any suggestions ... especially those that work! 

    Janie,

    1. Save your document as a .doc file (template as a .dot file).
    2. Make sure your macro has something in it to collapse the selection, otherwise your user is likely to delete your macrobutton with a stray keyboard click.

    selection.collapse

    will do.

    Was this answer helpful?

    0 comments No comments
  4. Anonymous
    2011-12-20T17:49:22+00:00

    Jane,

    I hope I am proved wrong but it appears the new graphic engine has broken this feature.  All I can manage is to add a few blank space after the image.  If the user clicks in that area then the macro will fire.

    Was this answer helpful?

    0 comments No comments