WorksheetBase.MailEnvelope 屬性

取得工作表的電子郵件標頭。

命名空間:  Microsoft.Office.Tools.Excel
組件:  Microsoft.Office.Tools.Excel.v4.0.Utilities (在 Microsoft.Office.Tools.Excel.v4.0.Utilities.dll 中)

語法

'宣告
Public ReadOnly Property MailEnvelope As MsoEnvelope
public MsoEnvelope MailEnvelope { get; }

屬性值

型別:Microsoft.Office.Core.MsoEnvelope
工作表的電子郵件標頭。

範例

下列程式碼範例會使用 MailEnvelope 屬性,會替工作表將工作表的 Name 指派給電子郵件標頭當簡介。

這是示範文件層級自訂的範例。

Private Sub SetMailEnvelopeIntro()
    Me.MailEnvelope.Introduction = _
        "This is worksheet " & Me.Name
    MsgBox("The MailEnvelope introduction is: " & _
        Me.MailEnvelope.Introduction)
End Sub
private void SetMailEnvelopeIntro()
{
    this.MailEnvelope.Introduction = "This is worksheet " + this.Name;
    MessageBox.Show("The MailEnvelope introduction is: " +
        this.MailEnvelope.Introduction);
}

.NET Framework 安全性

請參閱

參考

WorksheetBase 類別

Microsoft.Office.Tools.Excel 命名空間