Changing Console Background and Foreground Colors
Changing background and foreground colors on console applications is possible.
class Program { static void Main(string[] args) { Console.ForegroundColor = ConsoleColor.White; Console.BackgroundColor = ConsoleColor.Red; Console.WriteLine("Hello Vitademy"); } }
Console Output:
It's also possible to change the whole background color of command window:
static void Main(string[] args) { Console.ForegroundColor = ConsoleColor.White; Console.BackgroundColor = ConsoleColor.Red; Console.Clear(); Console.WriteLine("Hello Vitademy"); }