An enumeration for choosing the starting position of a DocumentViewerText.Find operation.
public enum DocumentViewerFindTextStart
Public Enum DocumentViewerFindTextStart
enum class DocumentViewerFindTextStart sealed
|0||BeginPosition||Default. Indicates that the search should run from the provided [DocumentViewerFindTextStart.BeginPosition] to the DocumentViewerFindText.EndPosition (or top of page 1 and bottom of the last page, if these values were null). This results in one total search from begin to end.|
|1||InSelection||Setting this value to DocumentViewerFindText.Start indicates that the search should begin at the first character inside the first text selection in the document. This position may be either DocumentViewerText.SelectedTextBegin or DocumentViewerText.SelectedTextEnd, depending on the direction of the search.
If no text is selected, DocumentViewerFindText.Start works like [DocumentViewerFindTextStart.BeginPosition] (the default).
This behavior is similar to that in [DocumentViewerFindTextStart.AfterSelection], but with the first character in the text selection instead of the character after the end of the selection. Effectively,
|2||AfterSelection||Setting this value to DocumentViewerFindText.Start indicates that the search should begin at the first character after the last text selection in the document. This position may be one character before or after DocumentViewerText.SelectedTextBegin or DocumentViewerText.SelectedTextEnd, depending on the direction of the search. If the search is forward / down the page, the starting point will be the character after DocumentViewerText.SelectedTextEnd; if the search is backward / up the page, the starting point will be the character before DocumentViewerText.SelectedTextBegin.
If no text is selected, DocumentViewerFindText.Start works like
The first search will occur from the starting point mentioned above to the position indicated by DocumentViewerFindText.EndPosition. If the starting position is before the
If DocumentViewerFindText.Loop or DocumentViewerFindText.FindAll is set to true, then a second search may be conducted from the [beginPosition] to the character before the starting point, provided that the starting point was within the bounds of the search as described above.
This behavior is similar to that in [DocumentViewerFindTextStart.InSelection], but with the first character after the text selection instead of the character inside the selection. Effectively, ]DocumentViewerFindTextStart.InSelection] will search the selection first, and [DocumentViewerFindTextStart.AfterSelection] will not.When using DocumentViewerFindText.SelectFirstResult, searching from the first character after the selection is useful for “Find Next” and “Find Previous” operations that cycle through all the matches in the bounds.
|3||ManualPosition||Indicates that the search should start from DocumentViewerFindText.ManualStartPosition .
If this value is provided to DocumentViewerFindText.Start, the search operation will use the value of DocumentViewerFindText.ManualStartPosition as the starting point. If DocumentViewerFindText.ManualStartPosition is null, the search will act as if DocumentViewerFindText.BeginPosition was passed to DocumentViewerFindText.Start instead.See DocumentViewerFindText.ManualStartPosition for more information.
DocumentViewerFindTextStart is an enum type that chooses where the DocumentViewerText.Find method will start its search within the provided begin and end parameters. While the DocumentViewerFindText.BeginPosition and DocumentViewerFindText.EndPosition properties specify the bounds of the search, it is the DocumentViewerFindText.Start that determines where the algorithm will begin searching.
If DocumentViewerFindText.Loop or DocumentViewerFindText.FindAll is true, then the text search operation will be cut into two parts – one search from the start to the
endPosition, and another from the
beginPosition to the character before the start.
For an example, see DocumentViewerText.Find.