Click here to Skip to main content
15,881,092 members
Articles / Web Development / XHTML

AJAX enabled collapsible form section

Rate me:
Please Sign up or sign in to vote.
3.57/5 (4 votes)
29 Dec 2008CPOL6 min read 40.5K   199   20  
An AJAX control that can hide or show a form section including handling validators nested in the section.
<%@ Control Language="C#" AutoEventWireup="true" CodeBehind="SubForm.ascx.cs" Inherits="Sample.Controls.SubForm" %>
   Phone Number <asp:TextBox runat="server" ID="phoneNumber">
            </asp:TextBox><br />
            
            <asp:RequiredFieldValidator ID="RequiredFieldValidator1" ErrorMessage="Phone Number is mandatory" runat="server" ControlToValidate="phoneNumber"></asp:RequiredFieldValidator>

By viewing downloads associated with this article you agree to the Terms of Service and the article's licence.

If a file you wish to view isn't highlighted, and is a text file (not binary), please let us know and we'll add colourisation support for it.

License

This article, along with any associated source code and files, is licensed under The Code Project Open License (CPOL)


Written By
Architect SABBEL Conseils Inc.
Canada Canada
I am a senior .NET Architect working as an independent consultant in the Montreal area (Canada). I have been programming for more than 24 years from which 14 years as a professional working mostly on online web applications.
I have an engineer degree in computer science and I am a SCRUM Master certified.
During my experience, I went through different languages; GW Basic, Pascal, Turbo Pascal, C, C++, Assembler (wrote an OS core all in assembler), Delphi, Visual Basic, ASP, ASP.NET 1.0 and 2.0 and some Java and PHP. Now, I am focusing on Microsoft technologies only. I also spend a lot of time studying and applying Agile methodologies (SCRUM) in different software development projects.
Apart from Computers, I like martial arts (brown belt in Kung Fu) and music (part time, not that good, musician ).
I am reachable on sbellouti@gmail.com.

Comments and Discussions