Publisher) (Shape.WebTextBox 屬性

會傳回與指定圖案相關的 WebTextBox 物件。

語法

運算式。WebTextBox

expression 一個用於表示 Shape 物件的變數。

傳回值

WebTextBox

範例

此範例會建立新的 Web 文字方塊、指定預設文字、指出輸入為必要,並將輸入限制為 50 個字元。

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

支援和意見反應

有關於 Office VBA 或這份文件的問題或意見反應嗎? 如需取得支援服務並提供意見反應的相關指導,請參閱 Office VBA 支援與意見反應。