System.Convert.ToString Method

Converts the value of the specified object to its equivalent string representation.

Syntax

public static string ToString (object value)

Parameters

value
An object that supplies the value to convert, or null.

Returns

The string representation of value, or string.Empty if value is null.

Remarks

To convert value to its string representation, the method tries to call the IConvertible.ToString(IFormatProvider) implementation of value. If value does not implement the IConvertible interface, the method tries to call the IFormattable.ToString(string, IFormatProvider) implementation of value. If value does not implement the IFormattable interface, the method calls the ToString method of the underlying type of value.

Requirements

Namespace: System
Assembly: mscorlib (in mscorlib.dll)
Assembly Versions: 1.0.5000.0, 2.0.0.0, 4.0.0.0