This is some old code that I am not too familiar with :
RequiredFieldValidator vldRequired = new RequiredFieldValidator();
vldRequired.Display = ValidatorDisplay.Dynamic;
vldRequired.Text = "*";
vldRequired.ControlToValidate = "txtSetting";
vldRequired.ID = "vldRequired";
vldRequired.Enabled = true;
vldRequired.ErrorMessage = SettingTitle + " is required";
returnCell.Controls.Add(vldRequired);
Where, IF you tab passed a required field the * will show up next to it. THE ErrorMessage only shows up when a Submit is clicked (that is all fine).
However, once you fill in the required field and tab out of the input, the “*” goes away but the ErrorMessage stays — I cannot figure out how to make that ErrorMessage go away when the * does.
Help?
Ok, I just ran into a similar issue on one of my projects. It’s been a while since I’ve used the requiredFieldValidator. Try removing your Text Property as it interferes with the Error Message. Also ensure that you don’t have a Validation Summary on the page as that may cause fixed messages to linger in front of the user even though they have corrected the the problem on the client side.