private void btnOnaylanmamisBakiye_Click(object sender, EventArgs e) { AcceptWallet acceptWallet = new AcceptWallet(users, index); acceptWallet.Show(); this.Hide(); }
private void btnOnayla_Click(object sender, EventArgs e) { secilen = dataGridView1.SelectedCells[0].RowIndex; SqlCommand bakiyeOnayla = new SqlCommand("Update KullaniciBilgileri SET GuncelBakiye=@p1,YeniBakiye=@p2 where ıd=@p3", sql.Connection()); bakiyeOnayla.Parameters.AddWithValue("@p1", users[index].YeniBakiye); bakiyeOnayla.Parameters.AddWithValue("@p2", 0); bakiyeOnayla.Parameters.AddWithValue("@p3", index + 1); bakiyeOnayla.ExecuteNonQuery(); MessageBox.Show("Bakiye onaylama işlemi başarılı!"); sql.Connection().Close(); users[index].GuncelBakiye = users[index].YeniBakiye; users[index].YeniBakiye = "0"; AcceptWallet acceptWallet = new AcceptWallet(users, index); acceptWallet.Show(); this.Hide(); }