ValidationSummary control at the top of the Web page

Q.  You are developing a Web page that contains many validated controls. You want to provide a detailed message for each validation error, but the page doesn’t have sufficient space to provide the detailed message next to each control. What can you do to indicate an error at the control and list the detailed error messages at the top of the Web page?
- Published on 27 Jul 15

a.
- Set the Text property of the validator control to the detailed message.
- Set the ErrorMessage property to an asterisk (*).
- Place a ValidationSummary control at the top of the Web page.
b.
- Set the ErrorMessage property of the validator control to the detailed message.
- Set the Text property to an asterisk (*).
- Place a ValidationSummary control at the top of the Web page.
c.
- Set the ToolTip property of the validator control to the detailed message.
- Set the ErrorMessage property to an asterisk (*).
- Place a ValidationSummary control at the top of the Web page.
d. None of the above

ANSWER:
- Set the ErrorMessage property of the validator control to the detailed message.
- Set the Text property to an asterisk (*).
- Place a ValidationSummary control at the top of the Web page.
 

    Discussion

  • Digvijay   -Posted on 14 Sep 15
    According to above question the sequence should be like

    • Set the ErrorMessage property of the validator control to the detailed message.
    • Set the Text property to an asterisk (*).
    • Place a ValidationSummary control at the top of the Web page.

    ValidationSummary control enables you to display a summary of all validation errors in a page. This control is useful when working with large forms. If a user enters the wrong value in a form field that is located at the end of the page, then the user might never see the error message. ValidationSummary control always display a list of errors at the top of the web page.

Post your comment / Share knowledge


Enter the code shown above:
 
(Note: If you cannot read the numbers in the above image, reload the page to generate a new one.)