ITextRangeProvider.MoveEndpointByRange Method

Moves one endpoint of a text range to the specified endpoint of a second text range.

Namespace:  System.Windows.Automation.Provider
Assembly:  System.Windows (in System.Windows.dll)

void MoveEndpointByRange(
	TextPatternRangeEndpoint endpoint,
	ITextRangeProvider targetRange,
	TextPatternRangeEndpoint targetEndpoint
)

Parameters

endpoint
Type: System.Windows.Automation.Text.TextPatternRangeEndpoint
The endpoint to move.
targetRange
Type: System.Windows.Automation.Provider.ITextRangeProvider
Another range from the same text provider.
targetEndpoint
Type: System.Windows.Automation.Text.TextPatternRangeEndpoint
An endpoint on the other range.

If the endpoint being moved crosses the other endpoint of the same text range then that other endpoint is moved also, resulting in a degenerate range and ensuring the correct ordering of the endpoints (that is, Start is always less than or equal to End).

Silverlight

Supported in: 5, 4

Silverlight for Windows Phone

Supported in: Windows Phone OS 7.1

For a list of the operating systems and browsers that are supported by Silverlight, see Supported Operating Systems and Browsers.

Community Additions

ADD
Show: