private void DispatchCommandExecution(Application application, int commandNumber) { try { BaseCommand command = application.GetCommand(commandNumber - 1); commandRuntime.Execute(command); } catch (Exception e) { console.WriteError("Invalid option. Try again."); console.WriteException(e); } }