private void login_to_all_sv() { bool isLogin = false; List <string> listCS = new List <string>(); // get all connecitonString exist listCS.Add(ConfigurationManager.ConnectionStrings["qltv_maychu"].ConnectionString + "User ID=" + txtUsername.Text + "; Password="******"qltv_tram_1"].ConnectionString + "User ID=" + txtUsername.Text + "; Password="******"qltv_tram_2"].ConnectionString + "User ID=" + txtUsername.Text + "; Password="******"qltv_tram_3"].ConnectionString + "User ID=" + txtUsername.Text + "; Password="******"qltv_tram_4"].ConnectionString + "User ID=" + txtUsername.Text + "; Password="******"User ID=" + txtUsername.Text + "; Password="******"Tài khoản hoặc mật khẩu không hợp lệ", "Lỗi"); } }
private void _login() { connectionString = ConfigurationManager.ConnectionStrings["qltv2"].ConnectionString; connectionString += "User ID=" + txtUsername.Text + "; Password="******"Login fail", "Error", MessageBoxButton.OK, MessageBoxImage.Error); } finally { conn.Close(); } } }
private void btnBack_Click(object sender, RoutedEventArgs e) { NavigationService navService = NavigationService.GetNavigationService(this); showOption pg = new showOption(connectionString); navService.Navigate(pg); }
private void btnTram_Click(object sender, RoutedEventArgs e) { Button btn = (Button)sender; int index = int.Parse(btn.Tag.ToString()); NavigationService navService = NavigationService.GetNavigationService(this); showOption sO = new showOption(listCS[index]); navService.Navigate(sO); }
private void btnBack_Click(object sender, RoutedEventArgs e) { navService = NavigationService.GetNavigationService(this); showOption pg = new showOption(connectionString); if (_addTaiLieu != null) { _addTaiLieu.get_dsTacGia(); navService.Navigate(_addTaiLieu); } else { navService.Navigate(pg); } //_ = _addTaiLieu != null ? navService.Navigate(tg) : navService.Navigate(pg); }