C# Convert ToString(Boolean)
Description
Convert ToString(Boolean)
converts the specified Boolean
value to its equivalent string representation.
Syntax
Convert.ToString(Boolean)
has the following syntax.
public static string ToString(
bool value
)
Parameters
Convert.ToString(Boolean)
has the following parameters.
value
- The Boolean value to convert.
Returns
Convert.ToString(Boolean)
method returns The string representation of value.
Example
/*from w w w . j av a2 s. com*/
using System;
public class MainClass{
public static void Main(String[] argv){
Console.WriteLine(Convert.ToString(true));
}
}
The code above generates the following result.