Inspector.EditorType プロパティ (Outlook)

エディターの種類を示す OlEditorType 定数を返します。 読み取り専用です。

構文

EditorType

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

注釈

Microsoft Office Outlook 2007 では、以降、 editortype プロパティ のプロパティは常に olEditorWord を返します。

この Microsoft Visual Basic Scripting Edition (VBScript) の例では、 Open イベントを使用して、アイテムの HTMLBody プロパティにアクセスします。 アイテムの Inspectoreditortype プロパティ のプロパティが olEditorHTML に設定します。 デザイン モードでフォームのスクリプト エディターで次のコードを配置すると、実行時にメッセージ ボックスは、フォームの本文として EditorTypeの変更が反映されます。 最後のメッセージ ボックスは、すべての VBScript コードをスクリプト エディターに表示するのには、 ScriptText プロパティを利用します。

Function Item_Open() 
 'Set the HTMLBody of the item. 
 Item.HTMLBody = "<HTML><H2>My HTML page.</H2><BODY>My body.</BODY></HTML>" 
 'Item displays HTML message. 
 Item.Display 
 'MsgBox shows EditorType is 2 which represents the HTML editor type 
 MsgBox "HTMLBody EditorType is " & Item.GetInspector.EditorType 
 'Access the Body and show 
 'the text of the Body. 
 MsgBox "This is the Body: " & Item.Body 
 'After accessing, EditorType 
 'is still 2. 
 MsgBox "After accessing, the EditorType is " & Item.GetInspector.EditorType 
 'Set the item's Body property. 
 Item.Body = "Back to default body." 
 'After setting the Body, EditorType is 
 'still the same. 
 MsgBox "After setting, the EditorType is " & Item.GetInspector.EditorType 
End Function

関連項目

Inspector オブジェクト

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

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