fixed catch block in main class
removed buttons, code refactoring