Export (0) Print
Expand All

Vector3D.Inequality Operator

Compares two Vector3D structures for inequality.

Namespace:  System.Windows.Media.Media3D
Assembly:  PresentationCore (in PresentationCore.dll)

public static bool operator !=(
	Vector3D vector1,
	Vector3D vector2
)

Parameters

vector1
Type: System.Windows.Media.Media3D.Vector3D

The first Vector3D structure to compare.

vector2
Type: System.Windows.Media.Media3D.Vector3D

The second Vector3D structure to compare.

Return Value

Type: System.Boolean
true if the X, Y, and Z components of vector3D1 and vector3D2 are different; false otherwise.

Two Vector3D structures are not equal if the values of their X, Y, and Z properties are different.

Vector3D values are described using Double values. Because the value of a Double can lose precision when operated upon, a comparison between two Vector3D values that are logically equal might fail.

The following example shows how to use the overloaded inequality operator to check if two Vector3D structures are not equal.

// Checks if two Vector3D structures are not equal using the overloaded inequality operator.

Vector3D vector1 = new Vector3D(20, 30, 40);
Vector3D vector2 = new Vector3D(45, 70, 80);
Boolean areNotEqual;

areNotEqual = (vector1 != vector2);
// areNotEqual is True

.NET Framework

Supported in: 4.5.2, 4.5.1, 4.5, 4, 3.5, 3.0

.NET Framework Client Profile

Supported in: 4, 3.5 SP1

Windows 8.1, Windows Server 2012 R2, Windows 8, Windows Server 2012, Windows 7, Windows Vista SP2, Windows Server 2008 (Server Core Role not supported), Windows Server 2008 R2 (Server Core Role supported with SP1 or later; Itanium not supported)

The .NET Framework does not support all versions of every platform. For a list of the supported versions, see .NET Framework System Requirements.

Show:
© 2014 Microsoft