static void Main()
        {
            //// {D19F100E-113F-4751-820C-FD5AF8D17A55}

            AppDomain.CurrentDomain.UnhandledException += new UnhandledExceptionEventHandler(CurrentDomain_UnhandledException);

            string strLoc = Assembly.GetExecutingAssembly().Location;
            FileSystemInfo fileInfo = new FileInfo(strLoc);
            string sExeName = fileInfo.Name;
            bool bCreatedNew;

            if (false == LanguageTranslator.SetLanguage(System.Threading.Thread.CurrentThread.CurrentCulture.TwoLetterISOLanguageName))
                LanguageTranslator.SetLanguage("en");

            mutex = new Mutex(true, "Global\\" + sExeName, out bCreatedNew);
            if (bCreatedNew)
                mutex.ReleaseMutex();
            else
            {
                BasicInfo.LoadRegistryValues();
                if (BasicInfo.SyncDirPath.Trim().Length != 0)
                {
                    string argument = BasicInfo.SyncDirPath;
                    System.Diagnostics.Process.Start(argument);
                }

                return;
            }

            Application.EnableVisualStyles();
            Application.SetCompatibleTextRenderingDefault(false);

            // Create the events tables since they weren't here last time.
            // The tables are only created if they don't already exist so
            // it is safe to make this call every time to be sure they exist.
            DbHandler dbHandler = new DbHandler();
            dbHandler.CreatedNewDatabase();
            dbHandler.CreateEventsTable();
            dbHandler.CreateIssueTable();

            // Clear any local events since the code will search for any local
            // changes and create events for them.
            dbHandler.ClearLocalEvents();

            dbHandler = null;

            frmLogin loginForm = new frmLogin();
            bool showLogin = loginForm.showLogin;

            if (showLogin)
            {
                Application.Run(loginForm);
            }
            else
            {
                loginForm.Login();
                Application.Run();
            }
        }