MAPIFolder.CurrentView 属性
定义
重要
一些信息与预发行产品相关,相应产品在发行之前可能会进行重大修改。 对于此处提供的信息,Microsoft 不作任何明示或暗示的担保。
返回表示 View 当前视图的 对象。 只读。
public:
property Microsoft::Office::Interop::Outlook::View ^ CurrentView { Microsoft::Office::Interop::Outlook::View ^ get(); };
public Microsoft.Office.Interop.Outlook.View CurrentView { get; }
Public ReadOnly Property CurrentView As View
属性值
注解
若要获取当前 Explorer视图的 View 对象,请使用 CurrentView 而不是 返回CurrentFolder的当前Folder对象的 CurrentView 属性。
您必须保存返回 CurrentView 之前继续将其用于任何目的的 视图 对象的引用。
若要正确重置当前视图,必须执行 , Reset() 然后 Apply()执行 。 下面的代码示例演示如何调用的顺序:
Sub ResetView()
Dim v as Outlook.View
' Save a reference to the current view object
Set v = Application.ActiveExplorer().CurrentView
' Reset and then apply the current view
v.Reset
v.Apply
End Sub
private void ResetView()
{
// Save a reference to the current view object
Outlook.View v = Application.ActiveExplorer().CurrentView
as Outlook.View;
// Reset and then apply the current view
v.Reset();
v.Apply();
}