Visio (Window.Windows 屬性)

會傳回 Microsoft Visio 實例或視窗的 Windows 集合。 唯讀。

語法

運算式窗戶

表達 代表 Window 物件的變數。

傳回值

Windows

註解

如果您的 Visual Studio 解決方案包含 Microsoft.Office.Interop.Visio 參考,則此屬性會對應至下列類型:

  • Microsoft.Office.Interop.Visio.IVWindow.Windows

範例

下列 Microsoft Visual Basic 巨集會取得 Application 物件的 Windows 集合,並在 [即時運算] 視窗中顯示集合中每個視窗的識別碼。

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 支援與意見反應