//Favorite button click private void favBtn_Click(object sender, MouseEventArgs e) { Button b = (Button)sender; FoodDonationForm frm2 = new FoodDonationForm(b.Tag.ToString(), b.Text); frm2.Show(); }
public void dgvDonorList_CellMouseClick(object sender, DataGridViewCellMouseEventArgs e) { try { int selectedRowIndex = dgvDonorList.CurrentCell.RowIndex; string ID = dgvDonorList.Rows[selectedRowIndex].Cells[0].Value.ToString().Trim(); string Name = dgvDonorList.Rows[selectedRowIndex].Cells[1].Value.ToString(); FoodDonationForm frm2 = new FoodDonationForm(ID, Name); frm2.Show(); } catch (Exception ex) { CCFBGlobal.appendErrorToErrorReport("", ex.GetBaseException().ToString()); } }
//Favorite button click private void favBtn_Click(object sender, MouseEventArgs e) { Button b = (Button)sender; FoodDonationForm frm2 = new FoodDonationForm(b.Name, b.Text); frm2.Show(); }