Microsoft® ASP.NET 4 Step by Step

Book description

Teach yourself the fundamentals of Web development with ASP.NET 4-one step at a time. With STEP BY STEP, you get the guidance and learn-by-doing examples you need to start building Web applications and Web services in the Microsoft Visual Studio(R) 2010 environment. The author-a highly regarded programming expert, writer, and instructor-illuminates ASP.NET features through practical examples that help developers quickly grasp concepts and apply techniques to the real world. The book also includes a companion CD with code samples, data sets, and a fully searchable eBook.



For customers who purchase an ebook version of this title, instructions for downloading the CD files can be found in the ebook.

Table of contents

  1. Microsoft® ASP.NET 4 Step by Step
  2. Dedication
  3. Acknowledgments
  4. Introduction
    1. Who This Book Is For
      1. Getting Started
      2. Finding Your Best Starting Point in This Book
    2. Conventions and Features in This Book
      1. Conventions
      2. Other Features
    3. Prerelease Software
    4. Hardware and Software Requirements
    5. Code Samples
      1. Digital Content for Digital Book Readers
      2. Installing the C# Code Samples
      3. Using the Code Samples
      4. Uninstalling the Code Samples
    6. Support for This Book
      1. We Want to Hear from You
  5. I. Fundamentals
    1. 1. Web Application Basics
      1. HTTP Requests
        1. HTTP Requests from a Browser
        2. Making HTTP Requests Without a Browser
      2. Hypertext Markup Language
      3. Dynamic Content
        1. HTML Forms
        2. Common Gateway Interface: Very Retro
        3. The Microsoft Environment as a Web Server
        4. Internet Information Services
        5. Internet Services Application Programming Interface DLLs
        6. Running Internet Information Services
      4. Classic ASP: Putting ASP.NET into Perspective
      5. Web Development Concepts
      6. ASP.NET
      7. Chapter 1 Quick Reference
    2. 2. ASP.NET Application Fundamentals
      1. The Canonical Hello World Application
        1. Mixing HTML with Executable Code
        2. Adding executable code inline
        3. Server-Side Executable Blocks
        4. Adding executable code using a script block
          1. A Trip Through the ASP.NET Architecture
      2. The ASP.NET Compilation Model
      3. Coding Options
        1. ASP.NET 1.x Style
        2. Modern ASP.NET Style
      4. The ASP.NET HTTP Pipeline
        1. The IIS 5.x and IIS 6.x Pipeline
        2. The IIS 7.x Integrated Pipeline
        3. Tapping the Pipeline
          1. The HttpApplication
          2. The HttpContext
          3. HttpModules
          4. HttpHandlers
      5. Visual Studio and ASP.NET
        1. Local IIS Web Sites
        2. File System–Based Web Sites
        3. FTP Web Sites
        4. Remote Web Sites
        5. Hello World and Visual Studio
          1. Generating the HelloWorld Web application
      6. Chapter 2 Quick Reference
    3. 3. The Page Rendering Model
      1. Rendering Controls as Tags
      2. Packaging the UI as Components
        1. The Page Using ASP.NET
        2. The Page’s Rendering Model
        3. The Page’s Control Tree
      3. Adding Controls Using Visual Studio
        1. Layout Considerations
      4. Chapter 3 Quick Reference
    4. 4. Custom Rendered Controls
      1. The Control Class
      2. Visual Studio and Custom Controls
      3. A Palindrome Checker
      4. Controls and Events
      5. HtmlTextWriter and Controls
      6. Controls and ViewState
      7. Chapter 4 Quick Reference
    5. 5. Composite Controls
      1. Composite Controls versus Rendered Controls
      2. Custom Composite Controls
      3. User Controls
      4. When to Use Each Type of Control
      5. Chapter 5 Quick Reference
    6. 6. Control Potpourri
      1. Validation
        1. How Page Validation Works
          1. Client-Side Validation
          2. Server-Side Validation
        2. Other Validators
        3. Validator Properties
      2. Image-Based Controls
      3. TreeView
      4. MultiView
      5. Chapter 6 Quick Reference
  6. II. Advanced Features
    1. 7. A Consistent Look and Feel
      1. Managing User Interface Consistency
      2. ASP.NET Master Pages
      3. Themes
      4. Skins
      5. Chapter 7 Quick Reference
    2. 8. Configuration
      1. Windows Configuration
      2. .NET Configuration
        1. Machine.Config
        2. Configuration Section Handlers
        3. Web.Config
        4. Managing Configuration in ASP.NET 1.x
        5. Managing Configuration in Later Versions of ASP.NET
      3. Configuring ASP.NET from IIS
      4. Chapter 8 Quick Reference
    3. 9. Logging In
      1. Web-Based Security
        1. Securing IIS
        2. Basic Forms Authentication
      2. ASP.NET Authentication Services
        1. The FormsAuthentication Class
        2. An Optional Login Page
      3. Managing Users
      4. ASP.NET Login Controls
      5. Authorizing Users
      6. Chapter 9 Quick Reference
    4. 10. Data Binding
      1. Representing Collections Without Data Binding
      2. Representing Collections with Data Binding
        1. ListControl-Based Controls
        2. TreeView Control
        3. Menu Control
        4. FormView Control
        5. GridView Control
        6. DetailsView Control
        7. DataList Control
        8. Repeater Control
      3. Simple Data Binding
      4. Accessing Databases
      5. The .NET Database Story
        1. Connections
        2. Commands
        3. Managing Results
          1. IDataReader
          2. DataSet
      6. ASP.NET Data Sources
      7. Other Data-Bound Controls
      8. LINQ
      9. Chapter 10 Quick Reference
    5. 11. Web Site Navigation
      1. ASP.NET Navigation Support
        1. Navigation Controls
        2. XML Site Maps
        3. The SiteMapProvider
        4. The SiteMap Class
        5. The SiteMapNode
      2. Using Navigation Controls
        1. The Menu and TreeView Controls
        2. The SiteMapPath Control
        3. Site Map Configuration
      3. Building Navigable Web Sites
      4. Trapping the SiteMapResolve Event
      5. Defining Custom Attributes for Each Node
      6. Security Trimming
      7. URL Mapping
      8. URL Rewriting
      9. Chapter 11 Quick Reference
    6. 12. Personalization
      1. Personalizing Web Visits
      2. Personalization in ASP.NET
        1. User Profiles
        2. Personalization Providers
      3. Using Personalization
        1. Defining Profiles in Web.Config
        2. Using Profile Information
        3. Saving Profile Changes
        4. Profiles and Users
      4. Chapter 12 Quick Reference
    7. 13. Web Parts
      1. A Brief History of Web Parts
      2. What Good Are Web Parts?
      3. Developing Web Parts Controls
        1. Web Parts Page Development
        2. Web Parts Application Development
      4. The Web Parts Architecture
        1. WebPartManager and WebZones
        2. Built-In Zones
        3. Built-In Web Parts
      5. Developing a Web Part
      6. Chapter 13 Quick Reference
  7. III. Caching and State Management
    1. 14. Session State
      1. Why Session State?
      2. ASP.NET and Session State
      3. Introduction to Session State
      4. Session State and More Complex Data
      5. Configuring Session State
        1. Turning Off Session State
        2. Storing Session State InProc
        3. Storing Session State in a State Server
        4. Storing Session State in a Database
      6. Tracking Session State
        1. Tracking Session State with Cookies
        2. Tracking Session State with the URL
        3. Using AutoDetect
        4. Applying Device Profiles
        5. Session State Timeouts
      7. Other Session Configuration Settings
      8. The Wizard Control: An Alternative to Session State
      9. Chapter 14 Quick Reference
    2. 15. Application Data Caching
      1. Getting Started with Caching
      2. Using the Data Cache
      3. Impact of Caching
      4. Managing the Cache
        1. DataSets in Memory
        2. Cache Expirations
        3. Cache Dependencies
        4. The SQL Server Dependency
        5. Clearing the Cache
      5. Chapter 15 Quick Reference
    3. 16. Caching Output
      1. Caching Page Content
      2. Managing Cached Content
        1. Modifying the OutputCache Directive
        2. The HttpCachePolicy
        3. Caching Locations
        4. Output Cache Dependencies
        5. Caching Profiles
      3. Caching User Controls
      4. When Output Caching Makes Sense
      5. Other Cache Providers
      6. Chapter 16 Quick Reference
  8. IV. Diagnostics and Plumbing
    1. 17. Diagnostics and Debugging
      1. Page Tracing
        1. Tracing
        2. Trace Statements
      2. Application Tracing
        1. Enabling Tracing Programmatically
        2. The TraceFinished Event
        3. Piping Other Trace Messages
      3. Debugging with Visual Studio
      4. Error Pages
      5. Unhandled Exceptions
      6. Chapter 17 Quick Reference
    2. 18. The HttpApplication Class and HTTP Modules
      1. The Application: A Rendezvous Point
      2. Overriding HttpApplication
        1. Application State Caveats
        2. Handling Events
          1. Application_Start
          2. Application_End
          3. Application_Error
          4. Application_BeginRequest
          5. Application_AuthenticateRequest
          6. Session_Start
          7. Session_End
        3. HttpApplication Events
      3. HttpModules
        1. Existing Modules
        2. Implementing a Module
        3. Seeing Active Modules
        4. Storing State in Modules
      4. Global.asax vs. HttpModules
      5. Chapter 18 Quick Reference
    3. 19. HTTP Handlers
      1. ASP.NET Request Handlers
      2. The Built-in Handlers
      3. Handlers and IHttpHandler
      4. Handlers and Session State
      5. Generic Handlers (ASHX Files)
      6. Chapter 19 Quick Reference
  9. V. Dynamic Data, XBAP, MVC, AJAX, and Silverlight
    1. 20. Dynamic Data
      1. Dynamic Data Controls
      2. Dynamic Data Details
      3. Chapter 20 Quick Reference
    2. 21. ASP.NET and WPF Content
      1. Improving Perceived Performance by Reducing Round-Trips
      2. What Is WPF?
        1. How Does WPF Relate to the Web?
        2. Loose XAML Files
        3. XBAP Applications
      3. WPF Content and Web Applications
      4. What About Silverlight?
      5. Chapter 21 Quick Reference
    3. 22. The ASP.NET MVC Framework
      1. The Model-View-Controller (MVC) Architecture
      2. ASP.NET and MVC
      3. ASP.NET MVC vs. Web Forms
      4. MVC and Testing
      5. How MVC Plays with ASP.NET
        1. Following the Request Path
      6. Chapter 22 Quick Reference
    4. 23. AJAX
      1. Rich Internet Applications
      2. What Is AJAX?
      3. ASP.NET and AJAX
        1. Reasons to Use AJAX
        2. Real-World AJAX
        3. AJAX in Perspective
      4. ASP.NET Server-Side Support for AJAX
        1. ScriptManager Control
        2. ScriptManagerProxy Control
        3. UpdatePanel Control
        4. UpdateProgress Control
        5. Timer Control
      5. AJAX Client Support
        1. ASP.NET AJAX Control Toolkit
        2. AJAX Control Toolkit Potpourri
      6. Getting Familiar with AJAX
      7. The Timer
      8. Updating Progress
      9. Extender Controls
        1. The AutoComplete Extender
        2. A Modal Pop-up Dialog-Style Component
      10. Chapter 23 Quick Reference
    5. 24. Silverlight and ASP.NET
      1. Web Applications Mature
      2. What Is Silverlight?
      3. Creating a Silverlight Application
      4. Architecture
      5. XAML
        1. Constructing the Visual Tree
        2. XAML and Namespaces
      6. Compiling the Silverlight Application
      7. Adding Silverlight Content to a Web Page
        1. Using the Object Tag
        2. Using the ASP.NET Silverlight Server-Side Control
        3. Using the JavaScript Function
      8. Controls and Events
        1. Routed Events
        2. Silverlight Controls and Class Members
      9. Silverlight and Layout
      10. Integrating with HTML
      11. Animations
      12. WCF Services and Silverlight
      13. Chapter 24 Quick Reference
  10. VI. Services and Deployment
    1. 25. Windows Communication Foundation
      1. Distributed Computing Redux
      2. A Fragmented Communications API
      3. WCF for Connected Systems
      4. WCF Constituent Elements
        1. Endpoints
          1. Address
          2. Binding
          3. Contract
        2. Channels
        3. Behaviors
        4. Messages
      5. How WCF Plays with ASP.NET
        1. Side-by-Side Mode
        2. ASP.NET Compatibility Mode
      6. Writing a WCF Service
      7. Building a WCF Client
      8. Chapter 25 Quick Reference
    2. 26. Deployment
      1. Visual Studio Web Sites
        1. HTTP Web Sites
        2. FTP Web Sites
        3. File System Web Sites
      2. Precompiling
        1. Precompiling for Performance
        2. Precompiling for Deployment
      3. Visual Studio 2010 Deployment Support
      4. Chapter 26 Quick Reference
  11. Index
  12. About the Author
  13. Copyright

Product information

  • Title: Microsoft® ASP.NET 4 Step by Step
  • Author(s): George Shepherd
  • Release date: May 2010
  • Publisher(s): Microsoft Press
  • ISBN: 9780735645318