added try catch in main menu.cs