0
votes

i am using validation control of asp.net . i got 10 fields and i have field validators with each of them . Now I want to show error but using ValidationSummary but errors also appear with individual validators. cant i close the individual error messages?

2

2 Answers

0
votes

have you add a validation group.

try like this

<asp:ValidationSummary ID="ValidationSummaryVerifyInfo" 
                        ValidationGroup="Verify" runat="server" DisplayMode="List" 
                        ShowMessageBox="True" ShowSummary="False"  />

<asp:RequiredFieldValidator ID="RFVEmail" runat="server" 
                        ErrorMessage="Please enter Email Id." ForeColor="Red" SetFocusOnError="True" 
                        ValidationGroup="Verify" ControlToValidate="TextBoxEmail">*</asp:RequiredFieldValidator>
0
votes

To hide the validators you can place them into one div with CSS style display: none.