Point4D.ToString 方法

定義

建立這個 String 結構的 Point4D 表示。

多載

ToString()

建立這個 String 結構的 Point4D 表示。

ToString(IFormatProvider)

建立這個 String 結構的 Point4D 表示。

ToString()

建立這個 String 結構的 Point4D 表示。

public:
 override System::String ^ ToString();
public override string ToString ();
override this.ToString : unit -> string
Public Overrides Function ToString () As String

傳回

String

傳回 String,其中包含這個 X 結構的 YZWPoint4D 值。

範例

下列範例示範如何取得 結構的字串表示 Point4D

// Gets a string representation of the structure
Point4D point1 = new Point4D(10, 5, 1, 4);
String pointString;

pointString = point1.ToString();
// matrixString is equal to 10, 5, 1, 4

// Displaying Results
syntaxString = "pointString = point1.ToString();";
resultType = "String";
operationString = "Getting the string representation of a Point4D";
ShowResults(pointString.ToString(), syntaxString, resultType, operationString);
' Gets a string representation of the structure
Dim point1 As New Point4D(10, 5, 1, 4)
Dim pointString As String

pointString = point1.ToString()
' matrixString is equal to 10, 5, 1, 4

' Displaying Results
syntaxString = "pointString = point1.ToString()"
resultType = "String"
operationString = "Getting the string representation of a Point4D"
ShowResults(pointString.ToString(), syntaxString, resultType, operationString)

適用於

ToString(IFormatProvider)

建立這個 String 結構的 Point4D 表示。

public:
 System::String ^ ToString(IFormatProvider ^ provider);
public string ToString (IFormatProvider provider);
override this.ToString : IFormatProvider -> string
Public Function ToString (provider As IFormatProvider) As String

參數

provider
IFormatProvider

文化特性 (Culture) 特有的格式資訊。

傳回

String

傳回 String,其中包含這個 X 結構的 YZWPoint4D 值。

範例

下列範例示範如何取得 結構的字串表示 Point4D

// Gets a string representation of the structure
Point4D point1 = new Point4D(10, 5, 1, 4);
String pointString;

pointString = point1.ToString();
// matrixString is equal to 10, 5, 1, 4

// Displaying Results
syntaxString = "pointString = point1.ToString();";
resultType = "String";
operationString = "Getting the string representation of a Point4D";
ShowResults(pointString.ToString(), syntaxString, resultType, operationString);
' Gets a string representation of the structure
Dim point1 As New Point4D(10, 5, 1, 4)
Dim pointString As String

pointString = point1.ToString()
' matrixString is equal to 10, 5, 1, 4

' Displaying Results
syntaxString = "pointString = point1.ToString()"
resultType = "String"
operationString = "Getting the string representation of a Point4D"
ShowResults(pointString.ToString(), syntaxString, resultType, operationString)

適用於