private void txtAccCentre_Leave(object sender, EventArgs e) { if (txtAccCentre.Text.Trim() != "") { if (txtAccCentre.Text.Length >= 3) { txtCurrency.Text = string.Empty; cbCurrency.DataSource = null; txtAccCentre.LostFocus += new EventHandler(txtAccCentre_LostFocus); } else { string result = CustomMessageBox.ShowBox("Filter text length should be greater than or equal to 3", "Error", ""); if (txtAccCentre.Text.Length == 0) { txtAccCentre.Text = "Code/Desc"; txtAccCentre.ForeColor = SystemColors.GrayText; } } } }
txtAccCentre.LostFocus += new EventHandler(txtAccCentre_LostFocus);
var
This content, along with any associated source code and files, is licensed under The Code Project Open License (CPOL)