S
Saikat Paul
Guest
private void DataGridView1_EditingControlShowing(object sender, DataGridViewEditingControlShowingEventArgs e)
{
if (DataGridView1.CurrentCell.ColumnIndex.Equals(1))
{
ComboBox Combo_ItemName = e.Control as ComboBox;
Combo_ItemName.SelectedIndexChanged += new EventHandler(Combo_ItemName_SelectedIndexChanged);
}
else if (DataGridView1.CurrentCell.ColumnIndex.Equals(3))
{
TextBox Quantity = e.Control as TextBox;
Quantity.TextChanged += new EventHandler(Quantity_TextChanged);
}
else if (DataGridView1.CurrentCell.ColumnIndex.Equals(5))
{
TextBox Discount = e.Control as TextBox;
Discount.TextChanged += new EventHandler(Discount_TextChanged);
}
}
Continue reading...
{
if (DataGridView1.CurrentCell.ColumnIndex.Equals(1))
{
ComboBox Combo_ItemName = e.Control as ComboBox;
Combo_ItemName.SelectedIndexChanged += new EventHandler(Combo_ItemName_SelectedIndexChanged);
}
else if (DataGridView1.CurrentCell.ColumnIndex.Equals(3))
{
TextBox Quantity = e.Control as TextBox;
Quantity.TextChanged += new EventHandler(Quantity_TextChanged);
}
else if (DataGridView1.CurrentCell.ColumnIndex.Equals(5))
{
TextBox Discount = e.Control as TextBox;
Discount.TextChanged += new EventHandler(Discount_TextChanged);
}
}
Continue reading...