StylusPoint.Inequality(StylusPoint, StylusPoint) Operador

Definição

Retorna um valor booliano que indica se os objetos StylusPoint especificados são diferentes.Returns a Boolean value which indicates whether the specified StylusPoint objects are unequal.

public:
 static bool operator !=(System::Windows::Input::StylusPoint stylusPoint1, System::Windows::Input::StylusPoint stylusPoint2);
public static bool operator != (System.Windows.Input.StylusPoint stylusPoint1, System.Windows.Input.StylusPoint stylusPoint2);
static member op_Inequality : System.Windows.Input.StylusPoint * System.Windows.Input.StylusPoint -> bool
Public Shared Operator != (stylusPoint1 As StylusPoint, stylusPoint2 As StylusPoint) As Boolean

Parâmetros

stylusPoint1
StylusPoint

O primeiro StylusPoint a ser comparado.The first StylusPoint to compare.

stylusPoint2
StylusPoint

O segundo StylusPoint a ser comparado.The second StylusPoint to compare.

Retornos

true se os objetos especificados StylusPoint forem diferentes, caso contrário, false.true if the specified StylusPoint objects are unequal; otherwise, false.

Exemplos

O exemplo a seguir demonstra como verificar se há dois objetos StylusPoint para desigualdade.The following example demonstrates how to check two StylusPoint objects for inequality. Como as propriedades X, Y e PressureFactor em point1 e point2 são definidas com o mesmo valor, os "dois objetos StylusPoint são iguais".Because the X, Y, and PressureFactor properties on point1 and point2 are set to the same value, the "The two StylusPoint objects are equal." A mensagem é exibida.Message appears.

StylusPoint point1 = new StylusPoint();
StylusPoint point2 = new StylusPoint();

point1.X = 150;
point1.Y = 400;
point1.PressureFactor = 0.45f;

point2.X = 150;
point2.Y = 400;
point2.PressureFactor = 0.45f;
Dim point1 As New StylusPoint()
Dim point2 As New StylusPoint()

point1.X = 150
point1.Y = 400
point1.PressureFactor = 0.45F

point2.X = 150
point2.Y = 400
point2.PressureFactor = 0.45F
if (point1 != point2)
{
    MessageBox.Show("The two StylusPoint objects are not equal.");
}
else
{
    MessageBox.Show("The two StylusPoint objects are equal.");
}
If point1 <> point2 Then
    MessageBox.Show("The two StylusPoint objects are not equal.")
Else
    MessageBox.Show("The two StylusPoint objects are equal.")
End If

Comentários

O método equivalente para esse operador é a negação de EqualsThe equivalent method for this operator is the negation of Equals

Aplica-se a