private void button_Click(object sender, RoutedEventArgs e) { userModel user = new userModel(); user.IdUser = ConfigurationManager.AppSettings["userid"]; user.Password = passfield.Password; result = userDAO.update(user); if (result > 0) { MessageBox.Show("Ubah password berhasil!"); } else { MessageBox.Show("Ubah password gagal!"); } }