Click here to Skip to main content
13,002,355 members (80,888 online)
Click here to Skip to main content

Stats

80.5K views
2.9K downloads
28 bookmarked
Posted 22 Apr 2009

ViewState in Dynamic Control

, 22 Apr 2009
Maintaining ViewState while working with Dynamic Control
<%@ Control Language="C#" AutoEventWireup="true" CodeFile="ContactDetails.ascx.cs"
    Inherits="UserControl_ContactDetails" EnableViewState="false"  %>
    <br />
<table width="100%" cellpadding="2" cellspacing="2" style="border:1px solid black;">
    <tr>
        <td>
            First Name
        </td>
        <td>
            <asp:TextBox ID="txtFirstName" runat="server"></asp:TextBox>
        </td>
        <td>
            Last Name
        </td>
        <td>
            <asp:TextBox ID="txtLastName" runat="server"></asp:TextBox>
        </td>
    </tr>
    <tr>
        <td>
            Address 1
        </td>
        <td>
            <asp:TextBox ID="txtAddress1" runat="server"></asp:TextBox>
        </td>
        <td>
            Address 2
        </td>
        <td>
            <asp:TextBox ID="txtAddress2" runat="server"></asp:TextBox>
        </td>
    </tr>
    <tr>
        <td>
            City
        </td>
        <td>
            <asp:TextBox ID="txtCity" runat="server"></asp:TextBox>
        </td>
        <td>
            Zip
        </td>
        <td>
            <asp:TextBox ID="txtZip" runat="server"></asp:TextBox>
        </td>
    </tr>
</table>

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)

Share

About the Author

BhadeliaImran
Team Leader Softwebsolutions INC
India India

Profiles : Code Project, ASP.NET Forums

Blog : Knowledgebase
World


Current Company : Softwebsolution
INC


User Group : Ahmedabad SQLServer UserGroup

Other : Microsoft Certified Technology Specialist (MCTS)

You may also be interested in...

Pro
Permalink | Advertise | Privacy | Terms of Use | Mobile
Web01 | 2.8.170626.1 | Last Updated 22 Apr 2009
Article Copyright 2009 by BhadeliaImran
Everything else Copyright © CodeProject, 1999-2017
Layout: fixed | fluid