Point.Parse(String) Yöntem

Tanım

Belirtilen Stringiçinden bir Point oluşturur.

public:
 static System::Windows::Point Parse(System::String ^ source);
public static System.Windows.Point Parse (string source);
static member Parse : string -> System.Windows.Point
Public Shared Function Parse (source As String) As Point

Parametreler

source
String

Bir noktanın dize gösterimi.

Döndürülenler

Point

Point Eşdeğer yapı.

Özel durumlar

source iki virgül veya boşlukla ayrılmış çift değerden oluşmaz.

source iki sayı içermez.

-veya- source çok fazla sınırlayıcı içeriyor.

Örnekler

Aşağıdaki örnekte, bir noktanın Point gösterimini Parse yapıya String dönüştürmek için yönteminin nasıl kullanılacağı gösterilmektedir.

private Point parseExample()
{

    // Converts a string representation of a point into a Point structure
    // using the Parse static method.
    // pointResult is equal to (1,3).
    Point pointResult = Point.Parse("1,3");

    return pointResult;
}
Private Function parseExample() As Point

    ' Converts a string representation of a point into a Point structure
    ' using the Parse static method.
    ' pointResult is equal to (1,3).
    Dim pointResult As Point = Point.Parse("1,3")

    Return pointResult

End Function

Şunlara uygulanır