Range.End Property 

Returns or sets the ending character position of a range.

Namespace: Microsoft.Office.Interop.Word
Assembly: Microsoft.Office.Interop.Word (in microsoft.office.interop.word.dll)

Usage

Dim range1 As Range

Dim returnValue As Integer
returnValue = range1.End

Dim sampleValue As Integer
range1.End = sampleValue

Syntax

Property End() As Integer
int End {get; set;}
property Int32 End{
    Int32 get();
    Void set(Int32);
}
public int get_End();
public void set_End(int);
function get End() : int;
function set End(int);

Remarks

If this property is set to a value smaller than the Start property, the Start property is set to the same value (that is, the Start and End property are equal).

The Selection, Range, and Bookmark objects all have a starting position and an ending position. The ending position is the point farthest away from the beginning of the story.

This property returns the ending character position relative to the beginning of the story. The main document story (wdMainTextStory) begins with character position 0 (zero). You can change the size of a selection, range, or bookmark by setting this property.

Thread Safety

Any public static (Shared in Visual Basic) members of this type are thread safe. Any instance members are not guaranteed to be thread safe.

Platforms

Development Platforms

Windows XP Home Edition, Windows XP Professional, Windows Server 2003, and Windows 2000

Target Platforms

See Also

Reference

Range Interface
Microsoft.Office.Interop.Word Namespace

Other Resources

Range Members