# Vector.ExplicitVector.ExplicitVector.Explicit Operator

## Surcharges

 Explicit(Vector to Point) Explicit(Vector to Point) Explicit(Vector to Point) Crée un Point avec les valeurs X et Y de ce vecteur.Creates a Point with the X and Y values of this vector. Explicit(Vector to Size) Explicit(Vector to Size) Explicit(Vector to Size) Crée un Size à partir des offsets de ce vecteur.Creates a Size from the offsets of this vector.

## Explicit(Vector to Point)Explicit(Vector to Point)Explicit(Vector to Point)

Crée un Point avec les valeurs X et Y de ce vecteur.Creates a Point with the X and Y values of this vector.

``````public:
static explicit operator System::Windows::Point(System::Windows::Vector vector);``````
``public static explicit operator System.Windows.Point (System.Windows.Vector vector);``
``static member op_Explicit : System.Windows.Vector -> System.Windows.Point``

#### Paramètres

vector
Vector Vector Vector

Vecteur à convertir.The vector to convert.

#### Retours

Point avec des valeurs de coordonnées X et Y égales aux valeurs offset X et Y de `vector`.A point with X- and Y-coordinate values equal to the X and Y offset values of `vector`.

### Exemples

L’exemple suivant montre comment convertir un Vector Pointen.The following example shows how to convert a Vector into a Point.

``````private Point overloadedExplicitOperatorExample2()
{
Vector vector1 = new Vector(20, 30);

// Explicitly converts a Vector structure into a Point structure.
// returnPoint is equal to (20, 30).
Point returnPoint = (Point)vector1;

return returnPoint;

}
``````
``````Private Function overloadedExplicitOperatorExample2() As Point
Dim vector1 As New Vector(20, 30)

' Explicitly converts a Vector structure into a Point structure.
' returnPoint is equal to (20, 30).
Dim returnPoint As Point = CType(vector1, Point)

Return returnPoint

End Function
``````

## Explicit(Vector to Size)Explicit(Vector to Size)Explicit(Vector to Size)

Crée un Size à partir des offsets de ce vecteur.Creates a Size from the offsets of this vector.

``````public:
static explicit operator System::Windows::Size(System::Windows::Vector vector);``````
``public static explicit operator System.Windows.Size (System.Windows.Vector vector);``
``static member op_Explicit : System.Windows.Vector -> System.Windows.Size``

#### Paramètres

vector
Vector Vector Vector

Vecteur à convertir.The vector to convert.

#### Retours

Un Size avec un Width égal à la valeur absolue de la propriété X de ce vecteur et un Height égal à la valeur absolue de la propriété Y de ce vecteur.A Size with a Width equal to the absolute value of this vector's X property and a Height equal to the absolute value of this vector's Y property.

### Exemples

L’exemple suivant montre comment convertir Vector explicitement Sizeen.The following example shows how to explicitly convert a Vector into a Size.

``````private Size overloadedExplicitOperatorExample1()
{
Vector vector1 = new Vector(20, 30);

// Explicitly converts a Vector structure into a Size structure.
// returnSize has a width of 20 and a height of 30.
Size returnSize = (Size)vector1;

return returnSize;

}
``````
``````Private Function overloadedExplicitOperatorExample1() As Size
Dim vector1 As New Vector(20, 30)

' Explicitly converts a Vector structure into a Size structure.
' returnSize has a width of 20 and a height of 30.
Dim returnSize As Size = CType(vector1, Size)

Return returnSize

End Function
``````