What you want to see on DotNetFunda.com ?
Go to DotNetFunda.com
Twitter TwitterLinkedIn
YouTubeGoogle
 Online : 18660 |  Welcome, Guest!   Register  Login
Home > Tutorials > ASP.NET Tutorials > ValidationSummary

Silverlight Tutorials | Report a Bug in the Tutorial
Found interesting? Add this to:


asp:ValidationSummary control
ValidationSummary control is used to summarize all validation errors on the page and display.
 
ValidationSummary control is used to summarize all validation errors on the page and display.

 

Following are main properties of the validation control.
ShowMessageBox true/false. Popup alert box with all validation error, if true.
ShowSummary true/false. Display summary of all errors on the page, if true.
DisplayMode BulletList/List/SingleParagraph. Used to display all validation errors in specified format.
HeaderText Used to write the header of the error summary.
ValidationGroup Used to specify the group name of input controls for which summary will be displayed.
DEMO : ValidationSummary Show Source Code
 
    
                    
// Form & Validation Control /////////////////////////
<asp:Label ID="lbl" AssociatedControlID="TextBox1" runat="Server" Text="Write into TextBox"></asp:Label>
    <asp:TextBox ID="TextBox1" runat="Server"></asp:TextBox>
    <asp:RequiredFieldValidator ID="req1" runat="Server" ControlToValidate="TextBox1" ErrorMessage="1st TextBox is Mandatory field" Text="<br>Please write something in 1st  Box."></asp:RequiredFieldValidator>
    <asp:Button ID="btnSubmit" runat="Server" OnClick="WriteTextBoxValue" Text="Submit" />                
    <asp:ValidationSummary ID="ValidationSummary" runat="Server" ShowMessageBox="true" ShowSummary="true" DisplayMode="List" HeaderText="Following error occured." />

                   





About Us | Contact Us | The Team | Advertise | Software Development | Write for us | Testimonials | Privacy Policy | Terms of Use | Link Exchange | Members | Go Top
General Notice: If you find plagiarised (copied) contents on this page, please let us know the original source along with your correct email id (to communicate) for further action.
Copyright © DotNetFunda.Com. All Rights Reserved. Copying or mimicking the site design and layout is prohibited. Logos, company names used here if any are only for reference purposes and they may be respective owner's right or trademarks. | 5/24/2013 6:29:03 PM