catch exception in main, and spawn a messagebox.