Back to description
Traditional Web pages use server-side technologies and resources to operate and deliver their features and services to... more
Traditional Web pages use server-side technologies and resources to operate and deliver their features and services to end users. These Web pages require end users to perform full-page postbacks to the server, where these pages can run the required server-side code to deliver the requested service or feature. In other words, these Web pages use the click-and-wait, user-unfriendly interaction pattern, which is characterized by waiting periods that disrupt user workflow and degrade the user experience. This click-and-wait user interaction pattern is what makes the traditional Web applications act and feel very different from their desktop counterparts.
Asynchronous JavaScript And XML (abbreviated AJAX) is a popular Web application development approach that uses client-side technologies such as HTML, XHTML, CSS, DOM, XML, XSLT, Javascript, and asynchronous client-callback techniques such as XMLHttp requests and hidden-frame techniques to develop more sophisticated and responsive Web applications that break free from the click-and-wait pattern and, consequently, act and feel more like a desktop applications. In other words, AJAX is closing the gap between the Web applications and their desktop counterparts.
XMLHttp
This chapter begins by discussing the main characteristics of AJAX-enabled Web pages in the context of an example.
... less
The main goal of the ASP.NET AJAX client-side framework is to emulate the ASP.NET and .NET Framework as much as possible... more
The main goal of the ASP.NET AJAX client-side framework is to emulate the ASP.NET and .NET Framework as much as possible to bring similar .NET-style programming to your client-side scripting. The ASP.NET AJAX JavaScript base type extensions are the first step toward achieving this goal.
These extensions extend the functionality of the JavaScript base types such as Array, Boolean, Date, Error, Number, Object, and String to add support for .NET-like methods and properties. As such, the ASP.NET AJAX JavaScript base type extensions make client-side programming against these JavaScript base types more like server-side programming against their .NET counterparts as much as possible.
Array
Boolean
Date
Error
Number
Object
String
The code samples presented in this chapter use a new JavaScript function named pageLoad and a new server control named ScriptManager as shown in the boldfaced portion of Listing 2-1.
pageLoad
ScriptManager
Listing 2-1: The ASP.NET page used by the examples
<%@ Page Language="C#" %>
<html xmlns="http://www.w3.org/1999/xhtml">
<head runat="server">
<title>Untitled Page</title>
<script language="JavaScript" type="text/javascript">
function pageLoad() {
. . .
}
</script>
</head>
<body>
<form id="form1" runat="server">
<asp:ScriptManager ID="ScriptManager1"
runat="server" />
</form>
</body>
</html>
I’ll discuss the pageLoad JavaScript function and ScriptManager server control in detail in future chapters. For now, here are two key concepts:
One of the responsibilities of the ScriptManager server control is to download the ASP.NET AJAX client-side script framework to the requesting browser to make it available to the browser’s JavaScript engine.
The ASP.NET AJAX client-side script framework automatically calls the pageLoad JavaScript function after the page and the related client-side scripts are completely loaded.
The previous chapter discussed two important ASP.NET AJAX JavaScript Error type extension functions named create... more
create
The previous chapter discussed two important ASP.NET AJAX JavaScript Error type extension functions named create and popStackFrame. This chapter shows you how the ASP.NET AJAX client-side script framework uses these two JavaScript functions to provide you with a set of .NET-like exception types. The chapter then presents you with a recipe for developing your own custom exception types in the ASP.NET AJAX client-side framework, and shows you how to use the recipe to implement a custom exception type.
popStackFrame
The .NET Framework comes with the following two important programming capabilities: ... more
The .NET Framework comes with the following two important programming capabilities:
Fully fledged typing and type reflection capabilities, allowing you to perform runtime-type inspections, discoveries, invocations, instantiations, and the like
Fully fledged object-oriented capabilities, allowing you to take full advantage of all the well-known benefits of object-oriented programming (OOP) such as classes, interfaces, inheritance, and the like
Because the main goal of the ASP.NET AJAX client-side framework is to emulate the ASP.NET and .NET Frameworks as much as possible, the ASP.NET AJAX client-side framework comes with a set of extensionsknown as the ASP.NET AJAX OOP and type reflection extensionsthat add .NET-like OOP and type reflection capabilities to JavaScript as much as possible.
You’ve already seen some reflection capabilities in Chapter 2 where the ASP.NET AJAX client-side Framework extends the JavaScript Object type to add support for the getType and getTypeName methods.
getType
getTypeName
The .NET Framework comes with an important class named Type that provides most of the reflection capabilities of the Framework. Following the same pattern, the ASP.NET AJAX client-side framework introduces a type named Type, which provides both OOP and type reflection capabilities, which I’ll discuss in this chapter.
Type
First, I’ll examine the JavaScript technologies that the ASP.NET AJAX OOP and type reflection extensions use under the hood to extend JavaScript to add OOP and type reflection support. This examination will put you in a much better position to understand and to use the ASP.NET AJAX client-side framework.
One of the great advantages of the .NET Framework is its event-programming facilities. The ASP.NET AJAX client-side framework... more
One of the great advantages of the .NET Framework is its event-programming facilities. The ASP.NET AJAX client-side framework provides you with similar facilities to make client-side JavaScript event programming more like server-side .NET event programming as much as possible. This chapter provides you with in-depth coverage of the ASP.NET AJAX event-programming extensions and examples that use these extensions.
Document Object Model (DOM) programming is one of the most common client-side programming tasks in the world of Web development.... more
Document Object Model (DOM) programming is one of the most common client-side programming tasks in the world of Web development. The ASP.NET AJAX DOM extensions extend traditional DOM programming to add support for .NET-like methods and properties. This chapter provides in-depth coverage of these extensions. As you’ll see in subsequent chapters, this convenient set of classes and enumerations are used extensively in the ASP.NET AJAX client-side framework.
The ASP.NET and .NET Frameworks provide server-side programmers with the necessary infrastructure for development components.... more
The ASP.NET and .NET Frameworks provide server-side programmers with the necessary infrastructure for development components. You can think of a component as a unit of functionality that implements a well-known API. A component may or may not have a visual presence in the user interface of an application. For example, a timer is a component that does not render visual markup in an ASP.NET page. A GridView, on the other hand, is a component that does render visual markup in a page. Thanks to the ASP.NET and .NET component development infrastructure, you can develop components such as GridView with minimal time and effort.
GridView
The ASP.NET AJAX client-side framework provides client-side programmers with a component-development infrastructure that emulates its ASP.NET and .NET counterparts to enable you develop client-side components with minimal time and effort. The ASP.NET AJAX component-development infrastructure consists of a set of well-defined interfaces and classes as discussed in this chapter.
First, this chapter presents the main interfaces that make up the ASP.NET AJAX component-development infrastructure. Then the chapter introduces two main classes of this infrastructure: Component and _Application.
Component
_Application
Every ASP.NET AJAX component (including your own custom components) directly or indirectly derives from the Component base class. This base class defines the lifecycle that every component application must go through. A component lifecycle consists of well-defined phases, as discussed in this chapter. Therefore, deriving your custom component classes (such as the Monitor class discussed in the previous chapter) from the Component base class automatically enables your component to participate in a typical component lifecycle.
Monitor
Every ASP.NET AJAX application is represented by an instance of the _Application class. This instance is created by the ASP.NET AJAX framework and exposed through the Sys.Application variable. The _Application class defines the lifecycle that every ASP.NET AJAX application must go through. An application lifecycle consists of well-defined phases, as discussed in this chapter.
Sys.Application
As discussed in the previous chapter, the Component class is the base class for all ASP.NET AJAX components.... more
As discussed in the previous chapter, the Component class is the base class for all ASP.NET AJAX components. The ASP.NET AJAX client-side framework includes two important subclasses of the Component base class: Sys.UI.Control and Sys.UI.Behavior. Therefore, when it comes to choosing a base class from which to derive your component class, you have three options: Component, Control, and Behavior. The previous chapter showed you how to implement an ASP.NET AJAX component that derives from the Component base class. This chapter first provides you with in-depth coverage of the Control class and its methods, properties, and events. Then it provides you with a recipe for developing ASP.NET AJAX components that derive from the Control class. Finally, it uses this recipe to implement a custom control class.
Sys.UI.Control
Sys.UI.Behavior
Control
Behavior
This chapter discusses the implementation of the ASP.NET AJAX Button client control and Web pages that use this control.... more
Button
This chapter discusses the implementation of the ASP.NET AJAX Button client control and Web pages that use this control. You’ll also learn how to implement custom client controls that bubble their events up to their parent client controls, and how to implement custom client controls that catch the events that their child controls bubble up.
The ASP.NET Framework provides you with two ways to inspect the metadata associated with a given type:... more
The ASP.NET Framework provides you with two ways to inspect the metadata associated with a given type: reflection and TypeDescriptor. Metadata inspection plays a central role in the ASP.NET Framework. For example, metadata inspection is an integral part of the ASP.NET server controls such as GridView, where data records come from many different data sources. It is a well-known fact that different types of data stores expose different types of data records. For example, data records stored into or retrieved from a relational database via the ADO.NET layer normally are of type DataRow or DataRowView. Data records stored into or retrieved from an XML document via the .NET XML layer are of type XmlNode.
TypeDescriptor
DataRow
DataRowView
XmlNode
If an ASP.NET server control such as GridView were to know about the actual type of the data records being retrieved or stored, it would be tied to a particular type of data record, and, consequently, a particular type of data store. For example, if an ASP.NET server control were to directly interact with the DataRow or DataRowView objects returned from the ADO.NET layer, it would not be able to interact with XmlNode objects returned from the .NET XML layer. In other words, the server control would only be able to retrieve data from and store data into a relational database via the ADO.NET layer and would not be able to retrieve data from and store data into an XML document via the .NET XML layer.
The metadata inspection capabilities of the .NET Framework allows a server control such as GridView to interact with the data records in generic fashion without knowing their actual types. This allows the same server control to retrieve and store any type of data records.
The ASP.NET AJAX client-side framework introduces two metadata inspection facilities that emulate their .NET counterparts, reflection and TypeDescriptor. Previous chapters covered the reflection capabilities of the ASP.NET AJAX client-side framework. This chapter discusses the ASP.NET AJAX type description capabilities, which emulate the .NET type description capabilities. As you’ll see later, the ASP.NET AJAX type descriptions provide the client controls with the same capabilities as their server counterparts. These capabilities enable the client controls to deal with data records in a generic fashion without having to know their actual types.
The ASP.NET AJAX type description infrastructure consists of the following main components:
ICustomTypeDescriptor
Tabular data, such as relational data, plays a central role in today’s data-driven Web applications.... more
Tabular data, such as relational data, plays a central role in today’s data-driven Web applications. The .NET Framework comes with three rich classes named DataColumn, DataRow, and DataTable that you can use in your .NET code to represent and to program against tabular data.
DataColumn
DataTable
The ASP.NET AJAX client-side script framework comes with the same set of data classesDataColumn, DataRow, and DataTablethat emulate their .NET countparts. You can use these data classes in your client-side code to represent and program against tabular data such as relational data. This chapter discusses these three ASP.NET AJAX data classes. All these classes belong to a namespace named Sys.Preview.Data:
Sys.Preview.Data
Type.registerNamespace('Sys.Preview.Data');
The ASP.NET AJAX DataTable class implements an interface named IData. The chapter begins with this interface.
IData
The ASP.NET AJAX client-server communication layer consists of several important types that are discussed in this chapter.... more
The ASP.NET AJAX client-server communication layer consists of several important types that are discussed in this chapter. These types emulate their ASP.NET/.NET counterparts, which enables you to use similar server-side network programming techniques in your client-side network programming. The types in the ASP.NET AJAX client-server communication layer belong to the following namespace:
Type.registerNamespace('Sys.Net');
The previous chapter discussed the ASP.NET AJAX client-server communication layer and its constituent components.... more
The previous chapter discussed the ASP.NET AJAX client-server communication layer and its constituent components. You learned how to use WebRequest, WebRequestManager, and WebRequestExecutor to make asynchronous requests to the server right from within your client-side code. This chapter builds on what you learned in the previous chapter to show you how to consume Web services in your ASP.NET AJAX applications. The chapter begins by implementing an ASP.NET Web service. It then shows you how to use the techniques that you learned in the previous chapter to consume this Web service in an ASP.NET AJAX application.
WebRequest
WebRequestManager
WebRequestExecutor
As you saw in the previous chapter, you can use the XMLHttpExecutor, WebRequestManager, and WebRequest... more
XMLHttpExecutor
As you saw in the previous chapter, you can use the XMLHttpExecutor, WebRequestManager, and WebRequest classes to make requests to the server. However, this approach requires you to write lot of code to make a request. The ASP.NET AJAX client-side framework includes a class named WebServiceProxy that encapsulates all the logic that uses the XMLHttpExecutor, WebRequestManager, and WebRequest classes to make a request to the server. This enables you to make a request with minimal time and effort. The downside of the WebServiceProxy approach is that it supports only JSON messages. If you need to use normal SOAP messages to communicate with a Web service, you have to use the techniques discussed in the previous chapter. This chapter begins by discussing the important members of the WebServiceProxy class.
WebServiceProxy
The previous chapter provided you with in-depth coverage of the ASP.NET AJAX REST method call request processing infrastructure.... more
The previous chapter provided you with in-depth coverage of the ASP.NET AJAX REST method call request processing infrastructure. This chapter shows you how this infrastructure hides its complexity behind proxy classes to enable you to program against a remote object as you would against a local object.
A behavior is a piece of functionality that can be attached to a DOM element. Therefore a behavior is a means of extending... more
A behavior is a piece of functionality that can be attached to a DOM element. Therefore a behavior is a means of extending the functionality of the DOM element to which the behavior is attached. Not every behavior can be attached to every DOM element. This chapter will provide you with in-depth coverage of some of the standard ASP.NET AJAX behaviors and help you gain the skills you need to develop your own custom behaviors.
In this chapter, I’ll implement fully functional replicas of those components of the ASP.NET AJAX server-side Framework... more
In this chapter, I’ll implement fully functional replicas of those components of the ASP.NET AJAX server-side Framework that are deeply involved in the internal functioning of two important types of server controls, known as script controls and extender controls, to help you gain a solid understanding of these server controls, how they interact with their associated client-side components, how they differ from one another, and how to implement your own custom script controls and extender controls. These components of the ASP.NET AJAX server side Framework include:
IExtenderControl
ExtenderControl
IScriptControl
ScriptControl
ScriptDescriptor
ScriptComponentDescriptor
ScriptBehaviorDescriptor
ScriptControlDescriptor
ScriptReference
ScriptReferenceCollection
This chapter will first provide an overview of the Amazon E-Commerce Web service. It will then implement a script server... more
This chapter will first provide an overview of the Amazon E-Commerce Web service. It will then implement a script server control that uses a Web services bridge to invoke a specified Web method of this Web service and display the results to end users. Finally, I will provide an in-depth coverage of ASP.NET AJAX transformers.
The ASP.NET AJAX Framework extends the ASP.NET Framework to add support for a new type of page postback that enables what... more
The ASP.NET AJAX Framework extends the ASP.NET Framework to add support for a new type of page postback that enables what is known as asynchronous partial page rendering or updates. The asynchronous partial page rendering is characterized by the following characteristics:
The values of the form elements are posted through an asynchronous HTTP request, allowing the end user to interact with the page while the request is sent and processed in the background. The asynchronous nature of the client-server communications goes a long way to improve the interactivity, responsiveness, and performance of ASP.NET AJAX applications.
When the server response arrives, only designated portions of the page are updated and re-rendered. The rest of the page remains intact, hence the name "partial page rendering." ASP.NET AJAX developers must use UpdatePanel server controls to tell the ASP.NET AJAX Framework which regions of a page must be updated on an asynchronous page postback.
UpdatePanel
The previous chapter developed two partial-rendering-enabled custom controls named BaseMasterDetailControl... more
BaseMasterDetailControl
The previous chapter developed two partial-rendering-enabled custom controls named BaseMasterDetailControl and BaseMasterDetailControl2, which I will use in this chapter to develop partial-rendering-enabled custom server controls. I’ll then use examples to show you how to use ASP.NET AJAX partial page rendering in your own Web applications.
BaseMasterDetailControl2
The main goal of this and the next few chapters is to help you gain a solid understanding of the ASP.NET AJAX asynchronous... more
The main goal of this and the next few chapters is to help you gain a solid understanding of the ASP.NET AJAX asynchronous page postback or partial-page-rendering-request-processing infrastructure. This infrastructure consists of two groups of components:
Server-side components: This group includes the ScriptManager, UpdatePanel, PageRequestManager, and ScriptRegistrationManager classes.
PageRequestManager
ScriptRegistrationManager
Client-side components: This group includes the PageRequestManager, WebRequest, WebRequestExecutor, WebRequestManager, XMLHttpExecutor, and Application classes, among others.
Application
Note that both the server and client sides contain a component named PageRequestManager. Even though they have the same name, they are two different components defined in two different frameworks. One is defined in the ASP.NET AJAX server-side framework while the other is defined in the ASP.NET AJAX client-side framework. For ease of reference, I’ll refer to the one defined in the server-side framework as the server-side PageRequestManager and the other as the client-side PageRequestManager. These components are at the heart of ASP.NET AJAX partial page rendering, which, as you'll see later, is the result of the communications between the client-side and server-side PageRequestManager components. As their names suggest, they’re the ones that are responsible for managing and processing asynchronous partial-page-rendering requests.
Here is how these two components work together. The current client-side PageRequestManager instance makes an asynchronous page postback request to the server. The current server-side PageRequestManager instance picks up and processes the request and sends the reponse text back to the client. The current client-side PageRequestManager instance then picks up and processes the response text and updates the regions of the page enclosed within the specified UpdatePanel server controls.
Your server-side code cannot directly access the current server-side PageRequestManager instance. Your code gets to interact with the current server-side PageRequestManager instance via the current ScriptManager server control, as you’ll see later in this chapter. Your client-side code, on the other hand, can directly access the current client-side PageRequestManager instance. This will all be cleared up later in this and the following chapters.
The last chapter followed the Page object through its life cycle phases to process the first request to a Web page enabled... more
Page
The last chapter followed the Page object through its life cycle phases to process the first request to a Web page enabled for partial page rendering. As you saw, the server response to this request contains a script block generated by the current server-side PageRequestManager instance. Recall that this script block takes the following two important actions:
Calls the _initialize static method on the client-side PageRequestManager class to instantiate and initialize the current client-side PageRequestManager instance
_initialize
Calls the _updateControls instance method on the current client-side PageRequestManager instance, passing in four parameters:
_updateControls
The first parameter is an array containing one string for each UpdatePanel server control on the current page. This string consists of two substrings. The first substring contains the letter t if the ChildrenAsTriggers property of the associated UpdatePanel server control has been set to true and the letter f otherwise. The second substring contains the value of the UniqueID property of the associated UpdatePanel server control.
t
ChildrenAsTriggers
true
f
UniqueID
The second parameter is an array that contains the UniqueID property values of all server controls on the current page that cause synchronous page postbacks.
The third parameter is an array that contains the UniqueID property values of all server controls on the current page that cause asynchronous page postbacks.
The fourth parameter is a string that contains the asynchronous postback request timeout.
Listing 22-1 presents an example of the script block rendered by the current server-side PageRequestManager instance.
Listing 22-1: The sample script block that arrives on the client side as part of the server response
<script type="text/javascript">
//<![CDATA[
Sys.WebForms.PageRequestManager._initialize('ScriptManager1',
document.getElementById('Form1'));
Sys.WebForms.PageRequestManager.getInstance()._updateControls(
['tUpdatePanel1', 'fUpdatePanel2', 'tUpdatePanel3'],
['SyncButton1', 'SyncButton2'],
['AsyncButton1', 'AsyncButton2'], ‘90’);
//]]
In this chapter we’ll move on to the client side, where the server response including this script block arrives. As you can see, this script block automatically invokes the _intialize and _updateControls methods of the client-side PageRequestManager. Figure 22-1 depicts the instantiation and initialization of the current PageRequestManager instance. As you can see, this figure diplays the two method calls I’ve discussed. Note that this figure contains two dashed lines. The top one represents the method calls triggered by the call into the _initialize method of the PageRequestManager. The bottom one represents the method calls triggered by the call into the _updateControls method. I’ll discuss these two sets of triggered method calls in the following sections, and update this figure with new method calls as we move through the chapter.
_intialize
The previous chapter followed the current client-side PageRequestManager instance as it made an asynchronous page postback... more
The previous chapter followed the current client-side PageRequestManager instance as it made an asynchronous page postback or partial-page-rendering request to the server. This chapter will move on to the server side to follow the asynchronous page postback request from the time it arrives in ASP.NET to the time the final response text is sent back to the server.
Chapter 21 followed the Page object as it went through its life cycle phases to process the first request made to a Web page enabled for partial page rendering. Since the first request wasn’t a postback, the Page object skiped the postback-related life cycle phases when it was processing the first request. This chapter, on the other hand, follows the current Page object as it goes through its life cycle phases to process an asynchronous page postback request to the same page that the first request downloaded. Since an asynchronous page postback is a postback request, the current Page will go through both postback and non-postback life cycle phases, shown in Listing 21-1 and Figure 21-2.
Since the non-postback life cycle phases were discussed thoroughly in Chapter 21, I’ll discuss only the postback-related life cycle phases in this chapter.
PageRequestMananger
This chapter will move on to the client side, where this server response text arrives, and follow the client-side PageRequestManager instance through its life cycle phases to process the server response. ... less
The xml-script is an XML document enclosed within the opening and closing tags of an HTML script... more
script
The xml-script is an XML document enclosed within the opening and closing tags of an HTML script element whose type attribute is set to text/xml-script. The xml-script, like any other XML document, has a single element known as the document element that encapsulates the rest of the xml-script. In other words, the document element is the outermost or containing element of an XML document. The document element in the case of the xml-script XML document is an element named page that belongs to an XML namespace named http://schemas.microsoft.com/xml-script/2005. The page document element contains a child element named components, which belongs to the same XML namespace as the page element. The descendants of the components element are the declarative representations of ASP.NET AJAX client-side objects.
type
text/xml-script
page
http://schemas.microsoft.com/xml-script/2005
components
The ASP.NET AJAX client-side framework comes with an extensible JavaScript library that parses the descendants of the components element, instantiates and initializes the ASP.NET AJAX client-side objects that these descendant elements represent, and adds these ASP.NET AJAX client-side objects to the current ASP.NET AJAX application. As you’ll see later, an ASP.NET AJAX client class named MarkupContext plays an important role in the logic that parses the xml-script document. Therefore, I’ll begin by discussing this class.
MarkupContext
The best way to understand what a binding is and what it does is to use it in an example. Listing B-1 contains a page... more
The best way to understand what a binding is and what it does is to use it in an example. Listing B-1 contains a page that binds the text property of the Label ASP.NET AJAX client control with an id property value of span1 to the text property of the TextBox ASP.NET AJAX client control with an id property value of text1. Thanks to this binding, every time you enter a different value in the text box, the span element associated with the Label control will be automatically updated with the new value.
Label
id
span1
text
TextBox
text1
span
Most ASP.NET AJAX client classes expose events. An action is an ASP.NET AJAX object that encapsulates a piece of client-side... more
Most ASP.NET AJAX client classes expose events. An action is an ASP.NET AJAX object that encapsulates a piece of client-side functionality that gets executed in response to a specified event of a specified ASP.NET AJAX object. All ASP.NET AJAX actions implement an interface named IAction, defined in Listing C-1. As you can see, this interface exposes the two methods described in the following table:
IAction
execute
setOwner
The ASP.NET framework comes with a server control named DataBoundControl that acts as the base class for important server... more
DataBoundControl
The ASP.NET framework comes with a server control named DataBoundControl that acts as the base class for important server controls such as GridView and DetailsView. The DataBoundControl base server control encapsulates the basic functionality that all data-bound controls must support. The ASP.NET AJAX client-side framework comes with a client control named DataControl that acts as the base control for important client controls such as ListView. The DataControl client control, just like its DataBoundControl server-side counterpart, encapsulates the base functionality that all data-bound client controls must support. In this appendix I’ll present and discuss the members of the DataControl base class to:
DetailsView
DataControl
ListView
Help you gain the skills you need to derive from this base class in order to implement your own custom data controls.
Set the stage for the Appendix F, where you’ll see how the ASP.NET AJAX ListView client control extends the functionality of the DataControl base class.
The DataControl base class belongs to a namespace named Sys.Preview.UI.Data, as defined in the following:
Sys.Preview.UI.Data
Type.registerNamespace('Sys.Preview.UI.Data');
Appendix D implemented a client control named CustomTable that uses predetermined HTML content to render its user interface... more
CustomTable
Appendix D implemented a client control named CustomTable that uses predetermined HTML content to render its user interface to display the specified data records. This client control is an example of a one that hard-codes its HTML content. A templated client control is a control that enables page developers to customize the HTML content that makes up its user interface. In other words, a templated client control does not hard-code its HTML. Every ASP.NET AJAX templated client control exposes a property of type ITemplate. As Listing E-1 shows, the ITemplate interface exposes the methods discussed in the following table:
ITemplate
createInstance
initialize
disposeInstance
Listing E-1: The ITemplate Interface
Sys.Preview.UI.ITemplate = function Sys$Preview$UI$ITemplate()
{
throw Error.notImplemented();
function Sys$Preview$UI$ITemplate$createInstance()
function Sys$Preview$UI$ITemplate$initialize()
Sys.Preview.UI.ITemplate.prototype =
createInstance: Sys$Preview$UI$ITemplate$createInstance,
initialize: Sys$Preview$UI$ITemplate$initialize
Sys.Preview.UI.ITemplate.registerInterface('Sys.Preview.UI.ITemplate');
Sys.Preview.UI.ITemplate.disposeInstance =
function Sys$Preview$UI$ITemplate$disposeInstance(container)
if (container.markupContext)
container.markupContext.dispose();
container.markupContext = null;
The ASP.NET AJAX ListView client control is a templated data control for displaying data records.... more
The ASP.NET AJAX ListView client control is a templated data control for displaying data records. A good understanding of the implementation of the ListView templated data control and its surrounding ASP.NET AJAX classes and interfaces will provide you with the skills, knowledge, and experience that you need to implement templated data controls as complex as the ListView.
However, before diving into the implementation of the ListView control and its surrounding ASP.NET AJAX classes and interfaces, I’ll uses a few examples to show you how to take advantage of the rich features of this control in your own Web applications.
Purchase Before purchasing this product, please be sure you have met all software and system requirements, and that you understand any limits placed upon its use.
Return Policy Wrox Chapters on Demand are non-returnable and non-refundable.
Reader Software Wrox Chapters on Demand are offered as PDFs, and they must be viewed using the Adobe Reader. If you do not have the Reader installed, it can be downloaded for free at Adobe.com.
Test Download As Wrox Chapters on Demand purchases are non-returnable, it is advisable that you test your system and software configurations with a free sample download before you place an order.
Usage Rights for a Wrox Chapter on Demand File Any Wrox Chapter on Demand product you purchase from this site will come with certain restrictions that allow Wiley to protect the copyrights of its products. After you purchase and download this title, you:
If you have any questions about these restrictions, you may contact Customer Care at (877) 762-2974 (8 a.m. - 5 p.m. EST, Monday - Friday). If you have any issues related to Technical Support, please contact us at 800-762-2974 (United States only) or 317-572-3994 (International) 8 a.m. - 8 p.m. EST, Monday - Friday).
Related Books
ASP.NET Resources