Share via


Outlook) (Selection.GetSelection 方法

會傳回 Selection 物件,其中包含 SelectionContents 參數所指定的物件類型,且目前已在使用中總管中選取。

語法

expressionGetSelection( _SelectionContents_ )

表達 代表 Selection 物件的變數。

參數

名稱 必要/選用 資料類型 描述
SelectionContents 必要 OlSelectionContents 指定選取範圍中要傳回的物件種類。

傳回值

包含在使用中檔案總管中所選取之指定種類的 Selection 物件。

註解

呼叫含 olConversationHeaders 引數的 GetSelection 時,所傳回 Selection 物件的 Location 屬性會等於 OlSelectionLocation.olViewList

如果目前的檢視不是交談檢視,或者 Selection.Location 不等於 OlSelectionLocation.olViewList,則呼叫含 olConversationHeaders 引數的 GetSelection 時,所傳回 Selection 物件的 Selection.Count 會等於 0。

另請參閱

Selection 物件

操作方法:取得及列舉選定交談

支援和意見反應

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