Windows apps
Collapse the table of content
Expand the table of content
Information
The topic you requested is included in another documentation set. For convenience, it's displayed below. Choose Switch to see the topic in its original location.

Complex::ToString Method ()

 

Converts the value of the current complex number to its equivalent string representation in Cartesian form.

Namespace:   System.Numerics
Assembly:  System.Numerics (in System.Numerics.dll)

public:
virtual String^ ToString() override

Return Value

Type: System::String^

The string representation of the current instance in Cartesian form.

The default string representation of a complex number displays the number using its Cartesian coordinates in the form (a, b), where a is the real part of the complex number, and b is its imaginary part. Both a and b are formatted using the general format specifier ("G") and the conventions of the current system culture.

The following example displays the string representation of several complex numbers. The output uses the formatting conventions of the English - United States ("en-US") culture, which, in this case, is the current system culture.

No code example is currently available or this language may not be supported.

Universal Windows Platform
Available since 8
.NET Framework
Available since 4.0
Portable Class Library
Supported in: portable .NET platforms
Silverlight
Available since 4.0
Windows Phone
Available since 8.1
Return to top
Show:
© 2017 Microsoft