WebCommandButton.ButtonType プロパティ (発行元)

Web コマンド ボタンがフォーム データをクリアするか送信するかを示す PbCommandButtonType 定数を返すか設定します。 値の取得と設定が可能です。

構文

ButtonType

WebCommandButton オブジェクトを表す変数。

戻り値

PbCommandButtonType

注釈

ButtonType プロパティ値は、Microsoft Publisher タイプ ライブラリで宣言されている PbCommandButtonType 定数のいずれかにすることができます。

この例では、新しい Web コマンド ボタンを作成し、その前面に表示されるテキストを割り当て、フォーム データの送信先のメール アドレスを指定します。

Sub NewWebForm() 
 With ActiveDocument.Pages.Add(Count:=1, After:=1) 
 With .Shapes.AddWebControl(Type:=pbWebControlCommandButton, _ 
 Left:=72, Top:=72, Width:=72, Height:=36) 
 With .WebCommandButton 
 .ButtonType = pbCommandButtonSubmit 
 .ButtonText = "Send Form:" 
 .EmailAddress = "someone@example.com" 
 End With 
 End With 
 End With 
End Sub

サポートとフィードバック

Office VBA またはこの説明書に関するご質問やフィードバックがありますか? サポートの受け方およびフィードバックをお寄せいただく方法のガイダンスについては、Office VBA のサポートおよびフィードバックを参照してください。