Learning ASP.NET 2.0 with AJAX

Book description

With this book, web developers can build engaging and interactive sites and applications using Microsoft's latest web development tools -- ASP.NET 2.0 and the new ASP.NET AJAX framework. You learn to create applications that have all the great tricks you see on popular commercial web sites, such as order forms and the ability to interact with a database. And you can build pages that display information interactively without a page refresh. This straightforward tutorial explains how.

Learning ASP.NET 2.0 with AJAX helps you master the concepts and techniques of Microsoft's tools with plenty of annotated examples, review quizzes, web construction exercises and chapter summaries, so you can practice new skills and test your understanding as you go. With it, you'll learn to:

  • Master the fundamental skills of ASP.NET 2.0 to build professional quality web applications


  • Integrate new Ajax tools and CSS with ASP.NET 2.0 for flashier and more interactive sites


  • Build applications with minimal coding using Visual Studio or its free counterpart, Visual Web Developer


  • Connect your site with a database so that users can retrieve, interact and save data


  • Debug your application, deal with unexpected problems, and protect your site from malicious users


  • Use the community-maintained ASP.NET AJAX Control Toolkit to extend the controls that come with ASP.NET AJAX


  • Use personalization tools to give your site a customized look for each user


Ideal for beginning web developers, or those who are new to ASP.NET, this book gets you involved with your own learning through hands-on lessons that are clear and to the point. You get the chance to try out new techniques on the spot. Want to join the world of modern web development? This book will get you started.

Publisher resources

View/Submit Errata

Table of contents

  1. Dedication
  2. A Note Regarding Supplemental Files
  3. Preface
    1. About This Book
    2. About This Series
    3. Learning or Programming?
    4. VB Versus C#
    5. How This Book Is Organized
    6. Conventions Used in This Book
    7. Support: A Note from Jesse Liberty
    8. Using Code Examples
    9. We’d Like to Hear from You
    10. Safari® Books Online
    11. Acknowledgments
      1. From Jesse Liberty
      2. From Dan Hurwitz
      3. From Brian MacDonald
  4. 1. Getting Started
    1. Hello World
    2. Creating a New Web Site
    3. Creating HelloWorld
    4. Making the HelloWorld Web Site Interactive
    5. What You Just Did
    6. Summary
    7. BRAIN BUILDER
      1. Quiz
      2. Exercises
  5. 2. Building Web Applications
    1. Mastering Web Site Fundamentals
      1. The Page
      2. Controls
      3. Code-Behind Files
      4. Events and Postbacks
      5. Synchronous and Asynchronous Postbacks
        1. The Page Load event and synchronous postback
        2. Adding asynchronous postbacks
    2. Controls
      1. Organizing the Properties Window
        1. Finding properties with IntelliSense
      2. Basic Controls
      3. Creating Tables
      4. Setting Properties
      5. Selection Controls
      6. Panels
      7. Selection Controls
        1. Adding controls with the Item editor
        2. Adding items in Source View
      8. More Selection Controls
      9. Displaying Text
      10. Images
      11. Links
      12. LinkButtons
    3. Source Code
    4. Summary
    5. BRAIN BUILDER
      1. Quiz
      2. Exercises
  6. 3. Snappier Web Sites with AJAX
    1. Take a Walk on the Client Side
    2. ScriptManager
    3. Extending Controls with the Control Toolkit
      1. TextBoxWaterMarkExtender
      2. PopupControlExtender
      3. CollapsiblePanelExtender
    4. Source Code Listing
    5. Summary
    6. BRAIN BUILDER
      1. Quiz
      2. Exercises
  7. 4. Saving and Retrieving Data
    1. Getting Data from a Database
      1. Binding Data Controls
      2. Create a Sample Web Page
      3. Using a DataSource Control
      4. “Pay No Attention to That Man Behind the Curtain”
      5. Using the GridView Control
      6. Auto-Generated Code
      7. Adding Insert, Update, and Delete Statements
    2. Displaying and Updating the Data
      1. Take It for a Spin
      2. Modifying the Grid Based on Events
      3. Selecting Data from the GridView
      4. Passing Parameters to the SELECT Query
    3. Source Code Listings
    4. Summary
    5. BRAIN BUILDER
      1. Quiz
      2. Exercises
  8. 5. Validation
    1. Validation Controls
    2. The RequiredFieldValidator
    3. The Summary Control
    4. The Compare Validator
      1. Checking the Input Type
      2. Comparing to Another Control
    5. Range Checking
    6. Regular Expressions
    7. Custom Validation
    8. Summary
    9. BRAIN BUILDER
      1. Quiz
      2. Exercises
  9. 6. Style Sheets, Master Pages, and Navigation
    1. Styles and Style Sheets
      1. Cascading Style Sheets
      2. Inline Styles
        1. Pros and cons
      3. Document-Level Styles
        1. Pros and cons
      4. External Style Sheets
    2. Master Pages
      1. Creating a Master Page
      2. Adding Content Pages
      3. Using Nested Master Pages
      4. Changing the Master Page at Runtime
    3. Navigation
      1. Buttons and HyperLinks
      2. Menus and Bread Crumbs
      3. Site Maps
      4. Using Sitemaps
        1. TreeView
        2. Customizing the look and feel of the TreeView
        3. Replacing the TreeView with a menu control
        4. Accessing site map nodes programmatically
      5. Bread Crumbs
    4. Summary
    5. BRAIN BUILDER
      1. Quiz
      2. Exercises
  10. 7. State and Life Cycle
    1. Page Life Cycle
    2. State
      1. View State
      2. Session State
      3. Application State
    3. Summary
    4. BRAIN BUILDER
      1. Quiz
      2. Exercises
  11. 8. Errors, Exceptions, and Bugs, Oh My!
    1. Creating the Sample Application
    2. Tracing
      1. Page-Level Tracing
      2. Inserting into the Trace Log
    3. Debugging
      1. The Debug Toolbar
      2. Breakpoints
        1. Setting a breakpoint
        2. Breakpoint window
        3. Breakpoint properties
        4. Breakpoint icons
      3. Stepping Through Code
      4. Examining Variables and Objects
      5. Debug Windows
        1. Immediate window
        2. Locals window
        3. Watch window
        4. Call Stack window
    4. Error Handling
      1. Unhandled Errors
      2. Application-Wide Error Pages
      3. Page-Specific Error Pages
    5. Summary
    6. BRAIN BUILDER
      1. Quiz
      2. Exercises
  12. 9. Security and Personalization
    1. Forms-Based Security
      1. Creating Users with the WAT
      2. Managing Users Programmatically
        1. Creating user accounts
        2. Creating a welcome page
        3. Creating a login page
      3. Roles
      4. Restricting Access
        1. Testing for login status
        2. Testing for role-based authentication membership
    2. Personalization
      1. Profiles
        1. Simple data types
        2. Complex data types
      2. Anonymous Personalization
        1. Migrating anonymous data to an actual user’s record
    3. Themes and Skins
      1. Create the Test Site
      2. Organize Site Themes and Skins
      3. Enable Themes and Skins
      4. Specify Themes for Your Page
      5. Using Named Skins
    4. Summary
    5. BRAIN BUILDER
      1. Quiz
      2. Exercises
  13. 10. Putting It All Together
    1. Getting Started
    2. Adding Styles
    3. Using Master Pages
    4. Setting Up Roles and Users
    5. Logging In
    6. Navigation
    7. Products Page
    8. Adding AJAX
    9. Cart Page
    10. Purchase Page
    11. Confirm Page
    12. Custom Error Pages
    13. Summary
    14. Source Code Listings
      1. Cart Page
      2. Confirm Page
      3. Home Page
      4. Login Page
      5. Master Page
      6. Products Page
      7. Purchase Page
      8. Web.config
  14. A. Installing the Applications
    1. What Hardware and Software You’ll Need
    2. Visual Web Developer (VWD)
      1. Installing VWD
      2. Configuring SQL Express
      3. Using the AdventureWorks Sample Database
    3. Visual Studio 2005
      1. Installing Visual Studio 2005
    4. ASP.NET AJAX
  15. B. Copying a Web Site
    1. Virtual Directories
      1. Outside the IDE
      2. Inside the IDE
    2. Copying the Web Site Without Using the IDE
    3. Copying the Web Site with the IDE
  16. C. Answers to Quizzes and Exercises
    1. Chapter 1: Getting Started
      1. Answers to Quiz Questions
      2. Answers to Exercises
    2. Chapter 2: Building Web Applications
      1. Answers to Quiz Questions
      2. Answers to Exercises
    3. Chapter 3: Snappier Web Sites with AJAX
      1. Answers to Quiz Questions
      2. Answers to Exercises
    4. Chapter 4: Saving and Retrieving Data
      1. Answers to Quiz Questions
      2. Answers to Exercises
    5. Chapter 5: Validation
      1. Answers to Quiz Questions
      2. Answers to Exercises
    6. Chapter 6: Style Sheets, Master Pages, and Navigation
      1. Answers to Quiz Questions
      2. Answers to Exercises
    7. Chapter 7: State and Life Cycle
      1. Answers to Quiz Questions
      2. Answers to Exercises
    8. Chapter 8: Errors, Exceptions, and Bugs, Oh My!
      1. Answers to Quiz Questions
      2. Answers to Exercises
    9. Chapter 9: Security and Personalization
      1. Answer to Quiz Questions
      2. Answers to Exercises
  17. Index
  18. About the Authors
  19. Colophon
  20. Copyright

Product information

  • Title: Learning ASP.NET 2.0 with AJAX
  • Author(s): Jesse Liberty, Dan Hurwitz, Brian MacDonald
  • Release date: September 2007
  • Publisher(s): O'Reilly Media, Inc.
  • ISBN: 9780596513979