void gcMultiRow_EditingControlShowing(object sender, EditingControlShowingEventArgs e)
{
// Change editing control's back color.
e.CellStyle.BackColor = Color.Red;
TextBox textBox = e.Control as TextBox;
if (textBox != null)
{
// Add TextChange event handler.
textBox.TextChanged -= new EventHandler(textBox_TextChanged);
textBox.TextChanged += new EventHandler(textBox_TextChanged);
}
}
Private Sub gcMultiRow_EditingControlShowing(ByVal sender As Object, ByVal e As EditingControlShowingEventArgs) Handles gcMultiRow.EditingControlShowing
' Change editing control's back color.
e.CellStyle.BackColor = Color.Red
Dim textBox As TextBox = TryCast(e.Control, TextBox)
If Not textBox Is Nothing Then
' Add TextChange event handler.
RemoveHandler textBox.TextChanged, AddressOf textBox_TextChanged
AddHandler textBox.TextChanged, AddressOf textBox_TextChanged
End If
End Sub