
- C# Basic Tutorial
- C# - Home
- C# - Overview
- C# - Environment
- C# - Program Structure
- C# - Basic Syntax
- C# - Data Types
- C# - Type Conversion
- C# - Variables
- C# - Constants
- C# - Operators
- C# - Decision Making
- C# - Loops
- C# - Encapsulation
- C# - Methods
- C# - Nullables
- C# - Arrays
- C# - Strings
- C# - Structure
- C# - Enums
- C# - Classes
- C# - Inheritance
- C# - Polymorphism
- C# - Operator Overloading
- C# - Interfaces
- C# - Namespaces
- C# - Preprocessor Directives
- C# - Regular Expressions
- C# - Exception Handling
- C# - File I/O
- C# Advanced Tutorial
- C# - Attributes
- C# - Reflection
- C# - Properties
- C# - Indexers
- C# - Delegates
- C# - Events
- C# - Collections
- C# - Generics
- C# - Anonymous Methods
- C# - Unsafe Codes
- C# - Multithreading
- C# Useful Resources
- C# - Questions and Answers
- C# - Quick Guide
- C# - Useful Resources
- C# - Discussion
Convert.ToString Method in C#
Convert the specified value to its equivalent string using the ToString() method.
Initialize a bool value.
bool boolVal = false;
Now, to convert it to a string, use the ToString() method.
Convert.ToString(boolVal)
The following is the complete example.
Example
using System; public class Demo { public static void Main() { bool boolVal = false; Console.WriteLine(Convert.ToString(boolVal)); } }
Output
False
- Related Articles
- Convert Long into String using toString() method of Long class in java
- Java toString() method.
- LocalDateTime toString() method in Java
- LocalTime toString() method in Java
- MonthDay toString() Method in Java
- Instant toString() method in Java
- LocalDate toString() method in Java
- ShortBuffer toString() method in Java
- Provider toString() method in Java
- Duration toString() method in Java
- Int64.ToString() Method in C#
- C# Enum ToString() Method
- Java Signature toString() method
- C# Int16.ToString() Method
- JavaScript RegExp toString() Method
- StringJoiner toString() method in Java 8

Advertisements