全部显示

Compatibility 属性

       

如果为 True,则启用由 Type 参数指定的兼容性选项。兼容性选项将影响 Microsoft Word 中文档的显示方式。Boolean 类型,可读写。

expression.Compatibility(Type)

expression   必需。该表达式返回一个 Document 对象。

Type  WdCompatibility,必需。兼容性选项。

说明

由于您选择或安装的语言支持(例如,英语(美国))不同,上述部分常量可能无法使用。

示例

本示例为活动文档启用“工具”菜单中“选项”对话框“兼容性”选项卡上的“取消硬分页符或分栏符前后的空格”选项。

ActiveDocument.Compatibility(wdSuppressSpBfAfterPgBrk) = True

本示例在启用或关闭“不为悬挂式缩进添加自动制表位”选项之间进行切换。

ActiveDocument.Compatibility(wdNoTabHangIndent) = Not _
    ActiveDocument.Compatibility(wdNoTabHangIndent)