【发布时间】:2016-04-28 03:38:27
【问题描述】:
假设我已经打开了 3 个 Outlook 检查器。
如何循环 3 个 Outlook 检查器?
所以,我需要一个如下所示的 vb.net 代码;
For Each i In All.Outlook.Inspectors
Next i
【问题讨论】:
假设我已经打开了 3 个 Outlook 检查器。
如何循环 3 个 Outlook 检查器?
所以,我需要一个如下所示的 vb.net 代码;
For Each i In All.Outlook.Inspectors
Next i
【问题讨论】:
以下代码使用 Inspectors 对象的 Inspectors 属性和 Count 属性和 Item 方法来显示所有检查器窗口的标题。
Dim myInspectors As Outlook.Inspectors
Dim x as Integer
Dim iCount As Integer
Set myInspectors = Application.Inspectors
iCount = Application.Inspectors.Count
If iCount > 0 Then
For x = 1 To iCount
MsgBox myInspectors.Item(x).Caption
Next x
Else
MsgBox "No inspector windows are open."
End If
Getting Started with VBA in Outlook 2010 文章可能对您有所帮助。
【讨论】: