Ejemplo n.º 1
0
        private void Main_FormClosing(object sender, FormClosingEventArgs e)
        {
            try
            {
                string extend = isExtended ? "True" : "False";

                SettingUtil.SaveSetting(extend);

                string query = string.Format("update TB_C_EXT set t_status = 'Offline' where t_staff = N'{0}'", GlobalService.User);
                DataServiceGeneral.GetInstance().ExecuteNonQuery(query);

                Process.GetCurrentProcess().Kill();
            }
            catch
            {
                Process.GetCurrentProcess().Kill();
            }
        }
Ejemplo n.º 2
0
        private void Login()
        {
            string query = string.Format("update TB_C_EXT set t_lastlogin = '******', t_status = 'Online' where t_staff = N'{1}'", DateTime.Now.ToString("yyyy/MM/dd HH:mm:ss"), GlobalService.User);

            DataServiceGeneral.GetInstance().ExecuteNonQuery(query);
        }