public static void MenuProcess() { IsMenuVisible = true; while (Menuchoice != "9") { if (IsMenuVisible == true) { Console.WriteLine("- - > Compare Tool v. 0.1 < - -"); Console.WriteLine(" "); Console.WriteLine("> MENU <\n"); Console.ForegroundColor = ConsoleColor.Cyan; Console.WriteLine("*** Please choose action, type the number and press Enter to proceed\n"); Console.ResetColor(); Console.WriteLine("1. Show avaiable files list\n"); Console.WriteLine("2. Select files\n"); Console.WriteLine("3. Show selected file names\n"); Console.WriteLine("4. Compare files\n"); Console.WriteLine("5. Show Discrepancies\n"); Console.WriteLine("9. \"Quit\". Exit\n"); Console.WriteLine("- - - - - - - - - - - - - - - -"); CheckIfDataReadyToCompare(); Console.WriteLine("- - - - - - - - - - - - - - - -"); Menuchoice = Console.ReadLine(); TextFilesComparator textFilesComparator = new TextFilesComparator(); switch (Menuchoice) { case "1": ShowUserChoice(Menuchoice); ShowAvailableFiles(); break; case "2": ShowUserChoice(Menuchoice); SetFilesForComparing(); break; case "3": ShowUserChoice(Menuchoice); ShowSelectedFiles(); break; case "4": ShowUserChoice(Menuchoice); CompareFiles(textFilesComparator); break; case "5": ShowUserChoice(Menuchoice); ShowDiscrepancies(textFilesComparator); break; case "9": break; default: ConsoleOutput.ShowMenuDialog("Sorry, invalid selection\n"); MakeMenuVisible(); break; } } } }