MoveEndWhile Method Example

This example moves the end position of the selection forward while the space character is found.

Selection.MoveEndWhile Cset:=" ", Count:=wdForward

This example moves the end position of the selection forward while Count is less than or equal to 10 and any letter from "a" through "h" is found.

Selection.MoveEndWhile Cset:="abcdefgh", Count:=10