Prev | Current Page 131 | Next

Rob Cameron and Dale Michalk

"Pro ASP.NET 3.5 Server Controls and AJAX Components"

Figure 2-10 shows that the
final output is identical in the browser.
CHAPTER 2 ?–  ENCAPSULATING FUNCT IONALITY IN ASP.NET 73
Figure 2-9. The Visual Studio Design view of custom table controls on a web form
Figure 2-10. Output from the table custom control demonstration web form
Listings 2-16 and 2-17 show TableCustomControlDemo??™s .aspx and class files.
74 CHAPTER 2 ?–  ENCAPSULATING FUNCT IONALITY IN A SP.NET
Listing 2-16. The TableCustomControlDemo Web Form .aspx File
<%@ Page Language="C#" MasterPageFile="~/MasterPage/ControlsBook2MasterPage.Master"
AutoEventWireup="true" CodeBehind="TableCustomControlDemo.aspx.cs"
Inherits="ControlsBook2Web.Ch02.TableCustomControlDemo"
Title="Table Custom Controls Demo" %>
<%@ Register TagPrefix="apress" Namespace="ControlsBook2Lib.Ch02"
Assembly="ControlsBook2Lib" %>

Width="14px">2  ID="ChapterTitleLabel" runat="server" Width="360px">
Encapsulating Functionality in ASP.NET



Table Custom Controls











runat="server" X="2" Y="2">


Listing 2-17.


Pages:
119 120 121 122 123 124 125 126 127 128 129 130 131 132 133 134 135 136 137 138 139 140 141 142 143