Table of contents
TOC
折叠目录
展开目录

FindReplace.Forward 属性 (发布服务器)FindReplace.Forward Property (Publisher)

office 365 dev account|上次更新日期: 2018/3/13
|
2 参与人员

设置或检索一个boolean 类型的值表示文本搜索的方向。如此如果查找操作在文档中向前搜索。如果向后搜索整个文档。读/写。Sets or retrieves a Boolean representing the direction of the text search. True if the find operation searches forward through the document. False if it searches backward through the document. Read/write.

语法Syntax

表达式前进expression. Forward

_expression_A 表示FindReplace对象的变量。_expression_A variable that represents a FindReplace object.

返回值Return Value

BooleanBoolean

注解Remarks

在替换文本时,转发必须设置为TrueForward must be set to True when replacing text.

示例Example

以下示例在每个打开的出版物中将所选内容中所有出现的单词“This”都替换为“That”。This example replaces all occurrences of the word "This" in the selection with "That" in each open publication.

Dim objDocument As Document 
For Each objDocument In Documents 
 With objDocument.Find 
 .Clear 
 .MatchCase = True 
 .FindText = "This" 
 .ReplaceWithText = "That" 
 .ReplaceScope = pbReplaceScopeAll 
 .Forward = True 
 .Execute 
 End With 
Next objDocument 
© 2018 Microsoft