Application.Windows 属性 (Visio)

返回 Microsoft Visio 实例或窗口的 Windows 集合。 此为只读属性。

语法

表达式窗户

expression:表示 Application 对象的变量。

返回值

Windows

示例

以下 Microsoft Visual Basic 宏获取 Application 对象的 Windows 集合并在“立即”窗口中打印集合中每个窗口的 ID。

Public Sub Windows_Example() 
 
 Dim vsoApplication As Visio.Application 
 Dim vsoWindows As Visio.Windows 
 Dim intCounter As Integer 
 
 'Get the Windows collection. 
 Set vsoApplication = Application 
 Set vsoWindows = vsoApplication.Windows 
 
 For intCounter = 1 To vsoWindows.Count 
 Debug.Print vsoWindows.Item(intCounter).ID 
 Next intCounter 
 
End Sub

支持和反馈

有关于 Office VBA 或本文档的疑问或反馈? 请参阅 Office VBA 支持和反馈,获取有关如何接收支持和提供反馈的指南。