ASP.NET 3.5 Unleashed

Book Description

ASP.NET 3.5 Unleashed is the most comprehensive book available on the Microsoft ASP.NET 3.5 Framework, covering all aspects of the ASP.NET 3.5 Framework--no matter how advanced.

This edition covers all the new features of ASP.NET 3.5. It explains Microsoft LINQ to SQL in detail. It includes a chapter on the two new data access controls introduced with the ASP.NET 3.5 Framework: ListView and DataPager. With its coverage of ASP.NET AJAX, this book shows you how to take advantage of Microsoft’s server-side AJAX framework to retrofit existing ASP.NET applications with AJAX functionality. It also demonstrates how to use Microsoft’s client-side AJAX framework to build the web applications of the future: pure client-side AJAX applications. All code samples are written in the C# programming language. (Visual Basic versions of all code samples are included on the CD-ROM that accompanies this book.)

  • Take advantage of Microsoft’s new database query language, LINQ to SQL, to easily build database-driven web applications

  • Learn how to use the new ListView and DataPager data access controls to build flexible user interfaces

  • Take advantage of ASP.NET AJAX when building both server-side and client-side web applications

  • Use the AJAX Control Toolkit to create auto-complete text fields, draggable panels, masked edit fields, and complex animations

  • Design ASP.NET websites

  • Secure your ASP.NET applications

  • Create custom components

  • Build highly interactive websites that can scale to handle thousands of simultaneous users

  • Learn to build a complete ASP.NET 3.5 website from start to finish–the last chapter of the book includes a sample ASP.NET 3.5 web application written with LINQ to SQL and ASP.NET AJAX

CD-ROM includes all examples and source code presented in this book in both C# and Visual Basic.

Table of Contents

  1. ASP.NET 3.5 Unleashed
    1. About the Author
    2. Acknowledgments
    3. We Want to Hear from You!
    4. Reader Services
    5. Introduction
        1. Who Should Read This Book?
        2. What Do You Need to Know Before You Read This Book?
        3. Changes to This Book
        4. How This Book Is Organized
    6. I. Building ASP.NET Pages
      1. 1. Overview of the ASP.NET Framework
          1. ASP.NET and the .NET Framework
            1. Understanding the Framework Class Library
              1. Understanding Namespaces
              2. Understanding Assemblies
            2. Understanding the Common Language Runtime
          2. Understanding ASP.NET Controls
            1. Overview of ASP.NET Controls
            2. Understanding HTML Controls
            3. Understanding and Handling Control Events
            4. Understanding View State
          3. Understanding ASP.NET Pages
            1. Understanding Dynamic Compilation
            2. Understanding Control Trees
            3. Using Code-Behind Pages
              1. How Code-Behind Works: The Ugly Details
              2. Deciding Between Single-File and Code-Behind Pages
            4. Handling Page Events
            5. Using the Page.IsPostBack Property
            6. Debugging and Tracing ASP.NET Pages
              1. Debugging ASP.NET Pages
              2. Debugging Pages with Visual Web Developer
            7. Tracing Page Execution
          4. Installing the ASP.NET Framework
          1. Summary
      2. 2. Using the Standard Controls
          1. Displaying Information
            1. Using the Label Control
            2. Using the Literal Control
          2. Accepting User Input
            1. Using the TextBox Control
            2. Using the CheckBox Control
            3. Using the RadioButton Control
          3. Submitting Form Data
            1. Using the Button Control
            2. Using the LinkButton Control
            3. Using the ImageButton Control
            4. Using Client Scripts with Button Controls
            5. Performing Cross-Page Posts
            6. Specifying a Default Button
            7. Handling the Command Event
          4. Displaying Images
            1. Using the Image Control
            2. Using the ImageMap Control
          5. Using the Panel Control
          6. Using the HyperLink Control
          1. Summary
      3. 3. Using the Validation Controls
          1. Overview of the Validation Controls
            1. Validation Controls and JavaScript
            2. Using Page.IsValid
            3. Setting the Display Property
            4. Highlighting Validation Errors
            5. Using Validation Groups
            6. Disabling Validation
          2. Using the RequiredFieldValidator Control
          3. Using the RangeValidator Control
          4. Using the CompareValidator Control
          5. Using the RegularExpressionValidator Control
          6. Using the CustomValidator Control
          7. Using the ValidationSummary Control
          8. Creating Custom Validation Controls
            1. Creating a LengthValidator Control
            2. Creating an AjaxValidator Control
          1. Summary
      4. 4. Using the Rich Controls
          1. Accepting File Uploads
            1. Saving Files to the File System
            2. Saving Files to a Database
            3. Uploading Large Files
          2. Displaying a Calendar
            1. Creating a Pop-up Date Picker
            2. Rendering a Calendar from a Database Table
          3. Displaying Advertisements
            1. Storing Advertisements in an XML File
            2. Storing Advertisements in a Database Table
            3. Tracking Impressions and Transfers
          4. Displaying Different Page Views
            1. Displaying a Tabbed Page View
            2. Displaying a Multi-Part Form
          5. Displaying a Wizard
          1. Summary
    7. II. Designing ASP.NET Websites
      1. 5. Designing Websites with Master Pages
          1. Creating Master Pages
            1. Creating Default Content
            2. Nesting Master Pages
            3. Using Images and Hyperlinks in Master Pages
            4. Registering Master Pages in Web Configuration
          2. Modifying Master Page Content
            1. Using the Title Attribute
            2. Using the Page Header Property
            3. Exposing Master Page Properties
            4. Using FindControl with Master Pages
          3. Loading Master Pages Dynamically
            1. Loading Master Pages Dynamically for Multiple Content Pages
          1. Summary
      2. 6. Designing Websites with Themes
          1. Creating Themes
          2. Adding Skins to Themes
            1. Creating Named Skins
            2. Themes Versus StyleSheetThemes
            3. Disabling Themes
            4. Registering Themes in the Web Configuration File
          3. Adding Cascading Style Sheets to Themes
            1. Adding Multiple Cascading Style Sheets to a Theme
            2. Changing Page Layouts with Cascading Style Sheets
          4. Creating Global Themes
          5. Applying Themes Dynamically
            1. Applying Skins Dynamically
          1. Summary
      3. 7. Creating Custom Controls with User Controls
          1. Creating User Controls
            1. Registering User Controls in the Web Configuration File
            2. Exposing Properties from a User Control
            3. Exposing Events from a User Control
            4. Creating an AddressForm Control
          2. AJAX and User Controls
          3. Dynamically Loading User Controls
            1. Using the Reference Directive
            2. Creating a Multi-Page Wizard
          1. Summary
    8. III. Performing Data Access
      1. 8. Overview of Data Access
          1. Using DataBound Controls
            1. Working with List Controls
            2. Working with Tabular DataBound Controls
            3. Working with Hierarchical DataBound Controls
            4. Working with Other Controls
          2. Using DataSource Controls
            1. Using ASP.NET Parameters with DataSource Controls
          3. Using Programmatic DataBinding
          4. Understanding Templates and DataBinding Expressions
            1. Using Templates
            2. Using DataBinding Expressions
            3. Using Two-Way DataBinding Expressions
          5. Overview of SQL Server 2005 Express
            1. Features of SQL Server Express
            2. SQL Server 2005 Express Management Tools
            3. Server Databases versus Local Databases
          6. Sample Database-Driven Web Application
          1. Summary
      2. 9. Using the SqlDataSource Control
          1. Creating Database Connections
            1. Connecting to Microsoft SQL Server
            2. Connecting to Other Databases
            3. Storing Connection Strings in the Web Configuration File
            4. Encrypting Connection Strings
          2. Executing Database Commands
            1. Executing Inline SQL Statements
            2. Executing Stored Procedures
            3. Filtering Database Rows
            4. Changing the Data Source Mode
            5. Handling SQL Command Execution Errors
            6. Canceling Command Execution
          3. Using ASP.NET Parameters with the SqlDataSource Control
            1. Using the ASP.NET Parameter Object
            2. Using the ASP.NET ControlParameter Object
            3. Using the ASP.NET CookieParameter Object
            4. Using the ASP.NET FormParameter Object
            5. Using the ASP.NET ProfileParameter Object
            6. Using the QueryStringParameter Object
            7. Using the SessionParameter Object
          4. Programmatically Executing SqlDataSource Commands
            1. Adding ADO.NET Parameters
            2. Executing Insert, Update, and Delete Commands
            3. Executing Select Commands
          5. Caching Database Data with the SqlDataSource Control
          1. Summary
      3. 10. Using List Controls
          1. Overview of the List Controls
            1. Declaring List Items
            2. Binding to a Data Source
            3. Determining the Selected List Item
            4. Appending Data Items
            5. Enabling Automatic PostBacks
            6. Using the Items Collection
          2. Working with the DropDownList Control
          3. Working with the RadioButtonList Control
          4. Working with the ListBox Control
          5. Working with the CheckBoxList Control
          6. Working with the BulletedList Control
          7. Creating a Custom List Control
          1. Summary
      4. 11. Using the GridView Control
          1. GridView Control Fundamentals
            1. Displaying Data
            2. Selecting Data
            3. Using Data Keys
            4. Sorting Data
              1. Sorting with AJAX
              2. Customizing the Sorting Interface
            5. Paging Through Data
              1. Paging with AJAX
              2. Customizing the Paging Interface
            6. Editing Data
              1. Handling Concurrency Issues
            7. Displaying Empty Data
            8. Formatting the GridView Control
            9. Using ViewState with the GridView Control
          2. Using Fields with the GridView Control
            1. Using BoundFields
            2. Using CheckBoxFields
            3. Using CommandFields
            4. Using ButtonFields
            5. Using HyperLinkFields
            6. Using ImageFields
            7. Using TemplateFields
          3. Working with GridView Control Events
            1. Highlighting GridView Rows
            2. Displaying Column Summaries
            3. Displaying Nested Master/Details Forms
          4. Extending the GridView Control
            1. Creating a LongTextField
            2. Creating a DeleteButtonField
            3. Creating a ValidatedField
          1. Summary
      5. 12. Using the DetailsView and FormView Controls
          1. Using the DetailsView Control
            1. Displaying Data with the DetailsView Control
            2. Using Fields with the DetailsView Control
            3. Displaying Empty Data with the DetailsView Control
            4. Paging Through Data with the DetailsView Control
              1. Paging with AJAX
              2. Customizing the Paging Interface
            5. Updating Data with the DetailsView Control
              1. Using Templates When Editing
              2. Handling Concurrency Issues
            6. Inserting Data with the DetailsView Control
            7. Deleting Data with the DetailsView Control
            8. Working with DetailsView Control Events
            9. Formatting the DetailsView Control
          2. Using the FormView Control
            1. Displaying Data with the FormView Control
            2. Paging Through Data with the FormView Control
            3. Editing Data with the FormView Control
            4. Inserting Data with the FormView Control
            5. Deleting Data with the FormView Control
          1. Summary
      6. 13. Using the Repeater and DataList Controls
          1. Using the Repeater Control
            1. Displaying Data with the Repeater Control
            2. Using Templates with the Repeater Control
            3. Handling Repeater Control Events
          2. Using the DataList Control
            1. Displaying Data with the DataList Control
            2. Displaying Data in Multiple Columns
            3. Using Templates with the DataList Control
            4. Selecting Data with the DataList Control
            5. Editing Data with the DataList Control
            6. Formatting the DataList Control
          1. Summary
      7. 14. Using the ListView and DataPager Controls
          1. Using the ListView Control
            1. Using the LayoutTemplate and ItemTemplate
            2. Using the GroupTemplate
            3. Selecting a Row
            4. Sorting Database Data
            5. Editing Database Data
          2. Using the DataPager Control
            1. Creating a Custom User Interface for Paging
            2. Data Source Paging with the DataPager Control
          1. Summary
    9. IV. Building Components
      1. 15. Building Components
          1. Building Basic Components
            1. Components and Dynamic Compilation
            2. Mixing Different Language Components in the App_Code Folder
            3. Declaring Methods
            4. Declaring Fields and Properties
            5. Declaring Constructors
            6. Overloading Methods and Constructors
            7. Declaring Namespaces
            8. Creating Partial Classes
            9. Inheritance and Abstract Classes
            10. Declaring Interfaces
            11. Using Access Modifiers
            12. Intellisense and Components
            13. Using ASP.NET Intrinsics in a Component
          2. Building Component Libraries
            1. Compiling Component Libraries
              1. Using the C# Command-Line Compiler
              2. Using Visual C# Express
              3. Using Visual Studio 2008
            2. Adding a Reference to a Class Library
              1. Adding an Assembly to the Bin Folder
              2. Adding an Assembly to the Global Assembly Cache
          3. Architectural Considerations
            1. Building Multi-Tier Applications
            2. Creating the User Interface Layer
            3. Creating the Business Logic Layer
            4. Creating the Data Access Layer
          1. Summary
      2. 16. Using the ObjectDataSource Control
          1. Representing Objects with the ObjectDataSource Control
            1. Binding to a Component
            2. Binding to a DataReader
            3. Binding to a DataSet
            4. Binding to a LINQ to SQL Query
            5. Binding to a Web Service
          2. Using Parameters with the ObjectDataSource Control
            1. Using Different Parameter Types
            2. Passing Objects as Parameters
          3. Paging, Sorting, and Filtering Data with the ObjectDataSource Control
            1. User Interface Paging
            2. Data Source Paging
            3. User Interface Sorting
            4. Data Source Sorting
            5. Filtering Data
          4. Handling ObjectDataSource Control Events
            1. Adding and Modifying Parameters
            2. Handling Method Errors
            3. Handling the ObjectCreating Event
          5. Concurrency and the ObjectDataSource Control
          6. Extending the ObjectDataSource Control
            1. Creating a Custom ObjectDataSource Control
            2. Creating Custom Parameter Objects
              1. Creating a Username Parameter
              2. Creating a Page Property Parameter
          1. Summary
      3. 17. Building Data Access Components with ADO.NET
          1. Connected Data Access
            1. Using the Connection Object
              1. Retrieving Provider Statistics
              2. Improving Performance with Connection Pooling
            2. Using the Command Object
              1. Executing a Command
              2. Executing a Command with Parameters
              3. Executing a Command That Represents a Stored Procedure
              4. Returning a Single Value
              5. Returning a Resultset
            3. Using the DataReader Object
              1. Returning Multiple Resultsets
              2. Working with Multiple Active Resultsets
          2. Disconnected Data Access
            1. Using the DataAdapter Object
              1. Performing Batch Updates
            2. Using the DataTable Object
              1. Selecting DataRows
              2. DataRow States and DataRow Versions
            3. Using the DataView Object
            4. Using the DataSet Object
          3. Executing Asynchronous Database Commands
            1. Using Asynchronous ADO.NET Methods
            2. Using Asynchronous ASP.NET Pages
          4. Building Database Objects with the .NET Framework
            1. Enabling CLR Integration
            2. Creating User-Defined Types with the .NET Framework
              1. Creating the User-Defined Type Assembly
              2. Registering the User-Defined Type Assembly with SQL Server
              3. Creating the User-Defined Type
            3. Building a Data Access Layer with a User-Defined Type
            4. Creating Stored Procedures with the .NET Framework
            5. Creating the Stored Procedure Assembly
              1. Registering the Stored Procedure Assembly with SQL Server
              2. Creating the Stored Procedures
              3. Executing a .NET Stored Procedure from an ASP.NET Page
          1. Summary
      4. 18. Data Access with LINQ to SQL
          1. New C# and VB.NET Language Features
            1. Understanding Automatic Properties
            2. Understanding Initializers
            3. Understanding Type Inference
            4. Understanding Anonymous Types
            5. Understanding Generics
            6. Understanding Lambda Expressions
            7. Understanding Extension Methods
            8. Understanding LINQ
          2. Creating LINQ to SQL Entities
            1. Building Entities by Hand
            2. Building Entities with the Object Relational Designer
            3. Building Entity Associations
            4. Using the LinqDataSource Control
          3. Performing Standard Database Commands with LINQ to SQL
            1. LINQ to Objects versus LINQ to SQL
            2. Selecting with LINQ to SQL
              1. Selecting Particular Columns
              2. Selecting Particular Rows
              3. Selecting Rows in a Particular Order
              4. Selecting a Single Row
              5. Performing a LIKE Select
              6. Paging Through Records
              7. Joining Records from Different Tables
              8. Caching Records
            3. Inserting with LINQ to SQL
            4. Updating with LINQ to SQL
            5. Deleting with LINQ to SQL
            6. Dynamic Queries
              1. Executing Dynamic SQL Statements
              2. Building Query Expressions Dynamically
            7. Debugging LINQ to SQL
              1. Using the LINQ to SQL Debug Visualizer
              2. Logging LINQ to SQL Queries
              3. Using the GetCommand Method
          4. Creating a Custom LINQ Entity Base Class
            1. Using the Entity Base Class
            2. Performing Standard Data-Access Operations with the EntityBase Class
            3. Performing Validation with the EntityBase Class
          1. Summary
    10. V. Site Navigation
      1. 19. Using the Navigation Controls
          1. Understanding Site Maps
          2. Using the SiteMapPath Control
            1. Formatting the SiteMapPath Control
          3. Using the Menu Control
            1. Declaratively Adding Menu Items
            2. Using the Menu Control with the MultiView Control
            3. Binding to a Site Map
            4. Binding to an XML File
            5. Binding to Database Data
            6. Formatting the Menu Control
            7. Using Templates with the Menu Control
          4. Using the TreeView Control
            1. Declaratively Adding Tree Nodes
            2. Displaying Check Boxes with the TreeView Control
            3. Binding to a Site Map
            4. Binding to an XML File
            5. Binding to Database Data
            6. Using Populate On Demand and AJAX
            7. Formatting the TreeView Control
          5. Building a SQL Hierarchical Data Source Control
          1. Summary
      2. 20. Using Site Maps
          1. Using the SiteMapDataSource Control
            1. Setting SiteMapDataSource Properties
          2. Using the SiteMap Class
            1. Using the SiteMapNode Class
          3. Advanced Site Map Configuration
            1. Using Security Trimming
            2. Merging Multiple Site Maps
            3. Creating Custom Site Map Attributes
          4. Creating Custom Site Map Providers
            1. Creating the AutoSiteMapProvider
            2. Creating the SqlSiteMapProvider
          5. Generating a Google SiteMap File
          1. Summary
      3. 21. Advanced Navigation
          1. Remapping URLs
            1. Creating a Custom UrlRemapper Module
          2. Using the VirtualPathProvider Class
            1. Limitations of the VirtualPathProvider Class
            2. Understanding the VirtualPathProvider Class
            3. Registering a VirtualPathProvider Class
            4. Storing a Website in Microsoft SQL Server
          1. Summary
    11. VI. Security
      1. 22. Using the Login Controls
          1. Overview of the Login Controls
          2. Using the Login Control
            1. Automatically Redirecting a User to the Referring Page
            2. Automatically Hiding the Login Control from Authenticated Users
            3. Using a Template with the Login Control
            4. Performing Custom Authentication with the Login Control
          3. Using the CreateUserWizard Control
            1. Configuring Create User Form Fields
            2. Sending a Create User Email Message
            3. Automatically Redirecting a User to the Referring Page
            4. Automatically Generating a Password
            5. Using Templates with the CreateUserWizard Control
            6. Adding Steps to the CreateUserWizard Control
          4. Using the LoginStatus Control
          5. Using the LoginName Control
          6. Using the ChangePassword Control
            1. Sending a Change Password Email
            2. Using Templates with the ChangePassword Control
          7. Using the PasswordRecovery Control
            1. Sending the Original Password
            2. Requiring a Security Question and Answer
            3. Using Templates with the PasswordRecovery Control
          8. Using the LoginView Control
            1. Using Roles with the LoginView Control
          1. Summary
      2. 23. Using ASP.NET Membership
          1. Configuring Authentication
            1. Configuring Forms Authentication
            2. Using Cookieless Forms Authentication
            3. Using Sliding Expiration with Forms Authentication
            4. Using Forms Authentication Across Applications
            5. Using Forms Authentication Across Domains
            6. Using the FormsAuthentication Class
            7. Using the User Class
          2. Configuring Authorization
            1. Authorizing by Role
            2. Authorizing Files by Location
            3. Using Authorization with Images and Other File Types
            4. Using Authorization with ASP Classic Pages
          3. Using ASP.NET Membership
            1. Using the Membership Application Programming Interface
            2. Encrypting and Hashing User Passwords
            3. Modifying User Password Requirements
            4. Locking Out Bad Users
            5. Configuring the SQLMembershipProvider
            6. Configuring the ActiveDirectoryMembershipProvider
              1. Configuring ADAM
              2. Configuring the ActiveDirectoryMembershipProvider
            7. Creating a Custom Membership Provider
          4. Using the Role Manager
            1. Configuring the SqlRoleProvider
              1. Using a Different Database with the SqlRoleProvider
            2. Configuring the WindowsTokenRoleProvider
            3. Configuring the AuthorizationStoreRoleProvider
            4. Caching Roles in a Browser Cookie
            5. Using the Roles Application Programming Interface
          1. Summary
    12. VII. Building ASP.NET Applications
      1. 24. Maintaining Application State
          1. Using Browser Cookies
            1. Cookie Security Restrictions
            2. Creating Cookies
            3. Reading Cookies
            4. Setting Cookie Properties
            5. Deleting Cookies
            6. Working with Multivalued Cookies
          2. Using Session State
            1. Storing Database Data in Session State
            2. Using the Session Object
            3. Handling Session Events
            4. Controlling When a Session Times Out
            5. Using Cookieless Session State
            6. Configuring a Session State Store
              1. Configuring State Server Session State
            7. Configuring SQL Server Session State
          3. Using Profiles
            1. Creating Profile Groups
            2. Supporting Anonymous Users
            3. Migrating Anonymous Profiles
            4. Inheriting a Profile from a Custom Class
            5. Creating Complex Profile Properties
            6. Saving Profiles Automatically
            7. Accessing Profiles from Components
            8. Using the Profile Manager
            9. Configuring the Profile Provider
            10. Creating a Custom Profile Provider
          1. Summary
      2. 25. Caching Application Pages and Data
          1. Overview of Caching
          2. Using Page Output Caching
            1. Varying the Output Cache by Parameter
            2. Varying the Output Cache by Control
            3. Varying the Output Cache by Header
            4. Varying the Output Cache by Browser
            5. Varying the Output Cache by a Custom Function
            6. Specifying the Cache Location
            7. Creating a Page Output Cache File Dependency
            8. Expiring the Page Output Cache Programmatically
            9. Manipulating the Page Output Cache Programmatically
            10. Creating Page Output Cache Profiles
          3. Using Partial Page Caching
            1. Using Post-Cache Substitution
            2. Caching with a User Control
            3. Sharing a User Control Output Cache
            4. Manipulating a User Control Cache Programmatically
            5. Creating a User Control Cache File Dependency
            6. Caching Dynamically Loaded User Controls
          4. Using DataSource Caching
            1. Using an Absolute Cache Expiration Policy
            2. Using a Sliding Cache Expiration Policy
            3. Caching with the ObjectDataSource Control
            4. Caching with the XmlDataSource Control
            5. Creating a DataSource Control Key Dependency
          5. Using Data Caching
            1. Using the Cache Application Programming Interface
            2. Adding Items to the Cache
            3. Adding Items with an Absolute Expiration Policy
            4. Adding Items with a Sliding Expiration Policy
            5. Adding Items with Dependencies
            6. Specifying Cache Item Priorities
            7. Configuring the Cache
          6. Using SQL Cache Dependencies
            1. Using Polling SQL Cache Dependencies
            2. Configuring Polling SQL Cache Dependencies
              1. Configuring a Database for Polling SQL Cache Dependencies
              2. Configuring an Application for Polling SQL Cache Dependencies
            3. Using Polling SQL Cache Dependencies with Page Output Caching
            4. Using Polling SQL Cache Dependencies with DataSource Caching
            5. Using Polling SQL Cache Dependencies with Data Caching
            6. Using Push SQL Cache Dependencies
            7. Configuring Push SQL Cache Dependencies
              1. Configuring a Database for Push SQL Cache Dependencies
              2. Configuring an Application for Push SQL Cache Dependencies
            8. Using Push SQL Cache Dependencies with Page Output Caching
            9. Using Push SQL Cache Dependencies with DataSource Caching
            10. Using Push SQL Cache Dependencies with Data Caching
          1. Summary
      3. 26. Localizing Applications for Multiple Languages
          1. Setting the Current Culture
            1. Setting a Culture Manually
            2. Automatically Detecting a Culture
            3. Setting the Culture in the Web Configuration File
            4. Culture and ASP.NET Controls
          2. Using the CultureInfo Class
            1. Using the CultureInfo Class to Format String Values
            2. Comparing and Sorting String Values
          3. Creating Local Resources
            1. Explicit Localization Expressions
            2. Implicit Localization Expressions
            3. Using Local Resources with Page Properties
            4. Retrieving Local Resources Programmatically
          4. Creating Global Resources
            1. Retrieving Global Resources Programmatically
            2. Using Strongly Typed Localization Expressions
          5. Using the Localize Control
          1. Summary
      4. 27. Working with the HTTP Runtime
          1. Creating a Custom BuildProvider
            1. Creating a Simple BuildProvider
            2. Creating a Data Access Component BuildProvider
          2. Creating a Custom ExpressionBuilder
            1. Creating a Lookup ExpressionBuilder
          3. Creating HTTP Handlers
            1. Creating a Generic Handler
            2. Implementing the IHttpHandler Interface
            3. Registering Extensions with Internet Information Server
            4. Creating an Asynchronous HTTP Handler
          4. Working with HTTP Applications and HTTP Modules
            1. Creating a Global.asax File
            2. Creating Custom HTTP Modules
          1. Summary
      5. 28. Configuring Applications
          1. Overview of Website Configuration
            1. Using the Web Site Administration Tool
            2. Using the ASP.NET Microsoft Management Console Snap-In
            3. ASP.NET Configuration Sections
            4. Applying Configuration Settings to a Particular Path
            5. Locking Configuration Settings
            6. Adding Custom Application Settings
            7. Placing Configuration Settings in an External File
          2. Using the Configuration API
            1. Reading Configuration Sections from the Current Application
            2. Opening a Configuration File
            3. Opening a Configuration File on a Remote Server
            4. Using the Configuration Class
            5. Modifying Configuration Sections
            6. Provisioning a New Website
          3. Creating Custom Configuration Sections
            1. Creating a Configuration Element Collection
          4. Creating Encrypted Configuration Sections
            1. Encrypting Sections with the aspnet_regiis tool
            2. Encrypting Sections Programmatically
            3. Deploying Encrypted Web Configuration Files
          1. Summary
    13. VIII. Custom Control Building
      1. 29. Building Custom Controls
          1. Overview of Custom Control Building
            1. Building Fully Rendered Controls
              1. Understanding the HtmlTextWriter Class
              2. Specifying the Containing WebControl Tag
            2. Building Composite Controls
            3. Building Hybrid Controls
          2. View State and Control State
            1. Supporting View State
            2. Supporting Control State
          3. Processing Postback Data and Events
            1. Handling Postback Data
            2. Handling Postback Events
              1. Passing Postback Event Arguments
              2. Using Postback Options
          4. Working with Control Property Collections
            1. Using the ParseChildren Attribute
            2. Using the AddParsedSubObject() Method
            3. Using a ControlBuilder
          5. Creating a Better Designer Experience
            1. Applying Design-Time Attributes to a Control
            2. Creating Control Designers
            3. Creating a Container ControlDesigner
            4. Adding Smart Tasks
          1. Summary
      2. 30. Building Templated Databound Controls
          1. Creating Templated Controls
            1. Implementing the ITemplate Interface
            2. Creating a Default Template
            3. Supporting Simplified Databinding
            4. Supporting Two-Way Databinding
          2. Creating Templated Databound Controls
            1. Creating a DivView Control
          1. Summary
    14. IX. ASP.NET AJAX
      1. 31. Using Server-Side ASP.NET AJAX
          1. The Ajax Vision
          2. Server-Side Ajax versus Client-Side Ajax
          3. Debugging Ajax Applications
          4. Using the UpdatePanel Control
            1. Specifying UpdatePanel Triggers
            2. Nesting UpdatePanel Controls
            3. Updating UpdatePanels Programmatically
            4. UpdatePanels and JavaScript
            5. UpdatePanel Server-Side Page Execution Lifecycle
            6. UpdatePanel Client-Side Page Execution Lifecycle
              1. InitializeRequestEventArgs
              2. BeginRequestEventArgs
              3. PageLoadingEventArgs
              4. PageLoadedEventArgs
              5. ApplicationLoadEventArgs
              6. EndRequestEventArgs
            7. Canceling the Current Asynchronous Postback
            8. Aborting the Previous Asynchronous Postback
            9. Passing Additional Information During an Asynchronous Postback
            10. Handling UpdatePanel Errors Gracefully
            11. UpdatePanel Performance
          5. Using the Timer Control
          6. Using the UpdateProgress Control
          1. Summary
      2. 32. Using the ASP.NET AJAX Control Toolkit
          1. Using the ASP.NET AJAX Control Toolkit
          2. Overview of the Toolkit Controls
          3. Using the AutoComplete Control
            1. Using the AutoCompleteExtender with a Page Method
            2. Using the AutoCompleteExtender with a Web Service Method
            3. Using Text and Value Pairs with the AutoCompleteExtender
          4. Using the DragPanel Control
          5. Using the FilteredTextBox Control
          6. Using the MaskedEdit Control
          7. Using the Animation Control
          8. Using the UpdatePanelAnimation Control
          1. Summary
      3. 33. Using Client-Side ASP.NET AJAX
          1. Making JavaScript Look Like C#
            1. Using the Microsoft AJAX Library
            2. Creating an AJAX Client Library
            3. Taking Advantage of JavaScript Intellisense
            4. Working with Classes
            5. Working with Inheritance
            6. Working with Namespaces
            7. Retrieving DOM Elements
            8. Handling DOM Events
            9. Retrieving DOM Event Information
            10. Creating Callbacks and Delegates
            11. Debug and Release AJAX Libraries
            12. Debugging Microsoft AJAX Applications
          2. Calling Web Services from the Client
            1. Calling an External Web Service
            2. Calling a Static Page Method
            3. Editing Movies with AJAX
            4. Using the Authentication Service
            5. Using the Role Service
            6. Using the Profile Service
          3. Creating Custom AJAX Controls and Behaviors
            1. Creating AJAX Controls
            2. Launching a Client-Side Control from the Server
              1. Creating a Server-Side AJAX User Control
              2. Creating a Server-Side AJAX Custom Control
            3. Creating Client-Side Behaviors
            4. Launching a Client-Side Behavior from the Server
          1. Summary
    15. X. Sample Application
      1. 34. Building a Code Sample Website
          1. Overview of the Sample Website
            1. Creating Blog Entries
            2. Creating Code Sample Entries
          2. Data Access and Validation
            1. Using LINQ to SQL
            2. Handling Common Database Operations
            3. Creating a Single Insert and Update Form
            4. Handling Form Validation
          3. Taking Advantage of Ajax
            1. Using the UpdatePanel Control
            2. Using the ASP.NET AJAX Control Toolkit
          4. Using the VirtualPathProvider Class
          1. Summary

Product Information

  • Title: ASP.NET 3.5 Unleashed
  • Author(s): Stephen Walther
  • Release date: March 2011
  • Publisher(s): Sams
  • ISBN: None