Changing name/caption on OLE object when it is added to doc via VB

K

ker_01

Word2007

I'm using the following code to add an option button to a document
(actually, dozens of them)

Selection.InlineShapes.AddOLEControl ClassType:="Forms.OptionButton.1"

Rather than going back in and changing the caption, group, and control name
by hand in the properties box, it makes sense to just change them as they are
being added by VBA.

However, I haven't found a way to either include these changes in the add
line above, nor have I been able to figure out the syntax to select the
optionbutton that was just added (e.g. Activedocument.Selection) to change
these properties.

Can anyone provide a little guidance?

Thank you,
Keith
 

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