private void Window_Closing(object sender, System.ComponentModel.CancelEventArgs e) { if (!isLogin) { CConfig.ConfigWrite(); Application.Current.Shutdown(); } }
private Boolean SaveData() { CConfig.SetKey(txtDesc.Password); CConfig.SetUrl(txtCode.Text); CConfig.ConfigWrite(); OnixWebServiceAPI.Init(CConfig.GetKey(), CConfig.GetUrl()); return(true); }
private void Window_Closing(object sender, System.ComponentModel.CancelEventArgs e) { if (isLogin) { Boolean result = CHelper.AskConfirmMessage("CONFIRM_EXIT"); if (result) { CUtil.EnableForm(false, this); CConfig.ConfigWrite(); OnixWebServiceAPI.Logout(new CTable("DUMMY")); CUtil.EnableForm(true, this); //e.Cancel = true; return; } e.Cancel = true; } CConfig.ConfigWrite(); }