Underline Constructor (TextPointer, TextPointer)

 
System_CAPS_noteNote

The .NET API Reference documentation has a new home. Visit the .NET API Browser on docs.microsoft.com to see the new experience.

Initializes a new instance of the Underline class, taking two TextPointer objects that indicate the beginning and end of a selection of content to be contained by the new Underline.

Namespace:   System.Windows.Documents
Assembly:  PresentationFramework (in PresentationFramework.dll)

new : 
        start:TextPointer *
        end:TextPointer -> Underline

Parameters

start
Type: System.Windows.Documents.TextPointer

A TextPointer indicating the beginning of a selection of content to be contained by the new Underline.

end
Type: System.Windows.Documents.TextPointer

A TextPointer indicating the end of a selection of content to be contained by the new Underline.

Exception Condition
ArgumentNullException

Raised when start or end is null.

ArgumentException

Raised when start and end do not resolve to a range of content suitable for enclosure by a Underline element, for example, if start and end indicate positions in different paragraphs.

This constructor is intended to initialize a new Underline element such that it encloses a selection of pre-existing content.

The following example demonstrates usage of this constructor.

No code example is currently available or this language may not be supported.

.NET Framework
Available since 3.0
Return to top
Show: