Partager via


Windows Interface

A collection of all the Window objects in Microsoft Excel.

Namespace:  Microsoft.Office.Interop.Excel
Assembly:  Microsoft.Office.Interop.Excel (in Microsoft.Office.Interop.Excel.dll)

Syntax

'Declaration
<InterfaceTypeAttribute()> _
<GuidAttribute("00020892-0000-0000-C000-000000000046")> _
Public Interface Windows _
    Inherits IEnumerable
'Usage
Dim instance As Windows
[InterfaceTypeAttribute()]
[GuidAttribute("00020892-0000-0000-C000-000000000046")]
public interface Windows : IEnumerable

Remarks

The Windows collection returned by the Windows property of the Application object contains all the windows in the application, whereas the Windows collection returned by the Windows property of the Workbook object contains only the windows in the specified workbook.

Use the NewWindow method of a Window or Workbook object to create a new window and add it to the collection.

Use Windows(index), where index is the window name or index number, to return a single Window object.

Note that the active window is always Windows(1).

See Also

Reference

Windows Members

Microsoft.Office.Interop.Excel Namespace