I am extremely new to this C# .Net so your patience is appreciated. I am working with Epicor ERP E11.
I have a field called Country of Origin(COO) that has a drop list of the countries. If the user types in an invalid country I want the field to go blank. The user input of the country is captured by (cmbCountryOrg.Text).
Now, the cmbCountryOrg.Text=""; works temporarily but only if the message box is displayed after it. The field reverts back to the user input country after clicking OK on the message box. Secondly, it does not work if the message box was displayed before it. Thirdly, it doesn't work at all without the message box.
I want the field to go blank after the user clicks ok on the message box.
Thanks
case "CountryofOrigin_c": DataTable dt1 = GetBAQ("NML_COOList");
string RowFilter1 = "Country_Description ='" + Convert.ToString(cmbCountryOrg.Text) + "'";
MessageBox.Show("RowFltr",RowFilter1);
DataTable dtFilter1 = Filter(dt1,RowFilter1);
if (dtFilter1.Rows.Count==0)
{
cmbCountryOrg.Text="";
MessageBox.Show("This is not a country");
}
break;
You can use this after the Submit button process.
Response.Redirectmethod helps us to clear the fields and get back to original.