Changed to GUI application, added error file dump