Bewerken

Delen via


WebOptionButton object (Publisher)

Represents a web option button control. The WebOptionButton object is a member of the Shape object.

Remarks

Use the Shapes.AddWebControl method to create a new web option button.

Use the Shape.WebOptionButton property to access a web option button control shape.

Example

This example creates a new web option button and specifies that its default state is selected; it then adds a text box next to it to describe it.

Sub CreateNewWebOptionButton() 
 With ActiveDocument.Pages(1).Shapes 
 With .AddWebControl(Type:=pbWebControlOptionButton, Left:=100, _ 
 Top:=123, Width:=16, Height:=10).WebOptionButton 
 .Selected = msoTrue 
 End With 
 With .AddTextbox(Orientation:=pbTextOrientationHorizontal, _ 
 Left:=120, Top:=120, Width:=70, Height:=15) 
 .TextFrame.TextRange.Text = "Advanced User" 
 End With 
 End With 
End Sub

Properties

See also

Support and feedback

Have questions or feedback about Office VBA or this documentation? Please see Office VBA support and feedback for guidance about the ways you can receive support and provide feedback.