閱讀英文

共用方式為


SnapshotPoint.Subtraction Operator (SnapshotPoint, SnapshotPoint)

Calculates the offset between two SnapshotPoint objects.

Namespace:  Microsoft.VisualStudio.Text
Assembly:  Microsoft.VisualStudio.Text.Data (in Microsoft.VisualStudio.Text.Data.dll)

Syntax

'宣告
Public Shared Operator - ( _
    start As SnapshotPoint, _
    other As SnapshotPoint _
) As Integer

Parameters

Return Value

Type: System.Int32
The offset between the two points, equivalent to start.Position - other.Position.

Exceptions

Exception Condition
ArgumentException

The two points do not belong to the same snapshot.

Remarks

The following should always be true: start == other + (start - other).

.NET Framework Security

See Also

Reference

SnapshotPoint Structure

Subtraction Overload

Microsoft.VisualStudio.Text Namespace