Point3D p1 = new Point3D(1, 2, 3); Point3D p2 = new Point3D(1, 2, 3); bool result = p1.Equals(p2); // result will be true
Point3D p1 = new Point3D(1, 2, 3); Point3D p2 = new Point3D(1, 2, 4); bool result = p1.Equals(p2); // result will be falseIn this example, we create two Point3D objects with different Z values. We then call the Equals method on the first point and pass in the second point as a parameter. The method returns false, indicating that the points are not equal. The Point3D.Equals method is part of the System.Windows.Media.Media3D namespace, which is included in the WindowsBase.dll package library.