语言

Windows 接口

定义

Microsoft Excel 中所有 Window 对象的集合。

public interface class Windows : System::Collections::IEnumerable
[System.Runtime.InteropServices.Guid("00020892-0000-0000-C000-000000000046")]
[System.Runtime.InteropServices.InterfaceType(2)]
public interface Windows : System.Collections.IEnumerable
Public Interface Windows
Implements IEnumerable
属性
实现

注解

对象属性Application返回的 Windows 集合Windows包含应用程序中的所有窗口,而对象属性Workbook返回WindowsWindows 集合仅包含指定工作簿中的窗口。

使用 Window 或 Workbook 对象的 NewWindow 方法创建新窗口并将其添加到集合中。

使用 Windows (index) (其中 index 为 窗口名称或索引号)返回单个 Window 对象。

注意,活动窗口总是 Windows(1)。

属性

名称 说明
_Default[Object]

仅供内部使用。

Application

返回表示 Application Microsoft Excel 应用程序的对象。

Count

返回集合中对象的数目。

Creator

返回一个 32 位整数,该整数指示在其中创建了此对象的应用程序。

Item[Object]

从集合中返回一个对象。

Parent

返回指定对象的父对象。

SyncScrollingSideBySide

如果为 True,在对文档进行并排比较的同时启用窗口内容的滚动功能。 如果该值为 False,则禁用同时滚动窗口。

方法

名称 说明
Arrange(XlArrangeStyle, Object, Object, Object)

对屏幕上的窗口进行排列。

BreakSideBySide()

使用此方法可结束两个窗口的并排模式。

CompareSideBySideWith(Object)

以并排模式打开两个窗口。

GetEnumerator()

Microsoft Excel 中所有 Window 对象的集合。

ResetPositionsSideBySide()

重置正在进行并排比较的两个工作表窗口的位置。

适用于