Ask Learn
Preview
Ask Learn is an AI assistant that can answer questions, clarify concepts, and define terms using trusted Microsoft documentation.
Please sign in to use Ask Learn.
Sign inThis browser is no longer supported.
Upgrade to Microsoft Edge to take advantage of the latest features, security updates, and technical support.
Note
Access to this page requires authorization. You can try signing in or changing directories.
Access to this page requires authorization. You can try changing directories.
Important
Some information relates to prerelease product that may be substantially modified before it’s released. Microsoft makes no warranties, express or implied, with respect to the information provided here.
Returns the string representation of the current Vector2 instance.
ToString() |
Returns the string representation of the current instance using default formatting. |
ToString(String) |
Returns the string representation of the current instance using the specified format string to format individual elements. |
ToString(String, IFormatProvider) |
Returns the string representation of the current instance using the specified format string to format individual elements and the specified format provider to define culture-specific formatting. |
Returns the string representation of the current instance using default formatting.
public:
override System::String ^ ToString();
public override string ToString();
public override readonly string ToString();
override this.ToString : unit -> string
Public Overrides Function ToString () As String
The string representation of the current instance.
This method returns a string in which each element of the vector is formatted using the "G" (general) format string and the formatting conventions of the current culture. The "<" and ">" characters are used to begin and end the string, and the current culture's NumberFormatInfo.NumberGroupSeparator property followed by a space is used to separate each element.
Product | Versions |
---|---|
.NET | Core 1.0, Core 1.1, Core 2.0, Core 2.1, Core 2.2, Core 3.0, Core 3.1, 5, 6, 7, 8, 9, 10 |
.NET Framework | 4.6, 4.6.1, 4.6.2, 4.7, 4.7.1, 4.7.2, 4.8, 4.8.1 |
.NET Standard | 2.0 (package-provided), 2.1 |
UWP | 10.0 |
Returns the string representation of the current instance using the specified format string to format individual elements.
public:
System::String ^ ToString(System::String ^ format);
public string ToString(string format);
public readonly string ToString(string? format);
public readonly string ToString(string format);
override this.ToString : string -> string
Public Function ToString (format As String) As String
A standard or custom numeric format string that defines the format of individual elements.
The string representation of the current instance.
This method returns a string in which each element of the vector is formatted using format
and the current culture's formatting conventions. The "<" and ">" characters are used to begin and end the string, and the current culture's NumberFormatInfo.NumberGroupSeparator property followed by a space is used to separate each element.
Product | Versions |
---|---|
.NET | Core 1.0, Core 1.1, Core 2.0, Core 2.1, Core 2.2, Core 3.0, Core 3.1, 5, 6, 7, 8, 9, 10 |
.NET Framework | 4.6, 4.6.1, 4.6.2, 4.7, 4.7.1, 4.7.2, 4.8, 4.8.1 |
.NET Standard | 2.0 (package-provided), 2.1 |
UWP | 10.0 |
Returns the string representation of the current instance using the specified format string to format individual elements and the specified format provider to define culture-specific formatting.
public:
virtual System::String ^ ToString(System::String ^ format, IFormatProvider ^ formatProvider);
public string ToString(string format, IFormatProvider formatProvider);
public readonly string ToString(string? format, IFormatProvider? formatProvider);
public readonly string ToString(string format, IFormatProvider formatProvider);
override this.ToString : string * IFormatProvider -> string
Public Function ToString (format As String, formatProvider As IFormatProvider) As String
A standard or custom numeric format string that defines the format of individual elements.
A format provider that supplies culture-specific formatting information.
The string representation of the current instance.
This method returns a string in which each element of the vector is formatted using format
and formatProvider
. The "<" and ">" characters are used to begin and end the string, and the format provider's NumberFormatInfo.NumberGroupSeparator property followed by a space is used to separate each element.
Product | Versions |
---|---|
.NET | Core 1.0, Core 1.1, Core 2.0, Core 2.1, Core 2.2, Core 3.0, Core 3.1, 5, 6, 7, 8, 9, 10 |
.NET Framework | 4.6, 4.6.1, 4.6.2, 4.7, 4.7.1, 4.7.2, 4.8, 4.8.1 |
.NET Standard | 2.0 (package-provided), 2.1 |
UWP | 10.0 |
.NET feedback
.NET is an open source project. Select a link to provide feedback:
Ask Learn is an AI assistant that can answer questions, clarify concepts, and define terms using trusted Microsoft documentation.
Please sign in to use Ask Learn.
Sign in