Table of contents
Collapse the table of content
Expand the table of content

Shape.WebTextBox Property (Publisher)

office 365 dev account|Last Updated: 8/24/2017
3 Contributors

Returns the WebTextBox object associated with the specified shape.


expression. WebTextBox

_expression_A variable that represents a Shape object.

Return Value



This example creates a new Web text box, specifies default text, indicates that entry is required, and limits entry to 50 characters.

Dim shpNew As Shape 
Dim wtbTemp As WebTextBox 

Set shpNew = ActiveDocument.Pages(1).Shapes _ 
 .AddWebControl(Type:=pbWebControlSingleLineTextBox, _ 
 Left:=100, Top:=100, Width:=150, Height:=15) 

Set wtbTemp = shpNew.WebTextBox 

With wtbTemp 
.DefaultText = "Please Enter Your Full Name" 
 .RequiredControl = msoTrue 
 .Limit = 50 
End With
© 2018 Microsoft