Buying Options
ASP.NET Cookbook
Safari Books Online
Add to Cart
What is this?

Product Editions

Please consider the latest edition.

  1. ASP.NET 2.0 Cookbook, Second Edition - December 2005
  2. ASP.NET Cookbook - August 2004
Description
This new book provides a wealth of solutions to problems commonly encountered when developing ASP.NET web applications in the popular problem-solution-discussion Cookbook format. For every problem, there's a worked-out solution or recipe a short, focused piece of code that web developers can insert directly into their applications. This ultimate ASP.NET code sourcebook will quickly earn the dog-eared corners and coffee rings that mark a web developer's most valued resource.
Full Description
Table of Contents
  1. Chapter 1 Tabular Data

    1. Introduction

    2. Selecting the Right Tabular Control

    3. Generating a Quick-and-Dirty Tabular Display

    4. Enhancing the Output of a Tabular Display

    5. Displaying Data from an XML File

    6. Displaying an Array as a Group of Checkboxes

    7. Displaying Data from a Hashtable

    8. Adding Next/Previous Navigation to a DataGrid

    9. Adding First/Last Navigation to a DataGrid

    10. Adding Direct Page Navigation to a DataGrid

    11. Paging Through a Record-Heavy DataGrid

    12. Sorting Data Within a DataGrid

    13. Sorting Data in Ascending/Descending Order Within a DataGrid

    14. Combining Sorting and Paging in a DataGrid

    15. Editing Data Within a DataGrid

    16. Formatting Columnar Data in a DataGrid

    17. Allowing Selection Anywhere Within a DataGrid Row

    18. Adding a Delete Confirmation Pop Up

    19. Displaying a Pop-Up Details Window

    20. Adding a Totals Row to a DataGrid

  2. Chapter 2 Validation

    1. Introduction

    2. Requiring that Data be Entered in a Field

    3. Requiring Data to Be In a Range

    4. Requiring that Two Data Input Fields Match

    5. Requiring that Data Matches a Predefined Pattern

    6. Requiring that a Drop-Down List Selection Be Made

    7. Requiring Data to Match a Database Entry

  3. Chapter 3 Forms

    1. Introduction

    2. Using the Enter Key to Submit a Form

    3. Using the Enter Key to Submit a Form After Validation

    4. Submitting a Form to a Different Page

    5. Simulating Multipage Forms

    6. Setting the Initial Focus to a Specific Control

    7. Setting the Focus to a Control with a Validation Error

  4. Chapter 4 User Controls

    1. Introduction

    2. Sharing a Page Header on Multiple Pages

    3. Creating a Customizable Navigation Bar

    4. Reusing Code-Behind Classes

    5. Communicating Between User Controls

    6. Adding User Controls Dynamically

  5. Chapter 5 Custom Controls

    1. Introduction

    2. Combining HTML Controls in a Single Custom Control

    3. Creating a Custom Control with Attributes

    4. Creating a Custom Control with State

    5. Customizing an ASP.NET TextBox Server Control

  6. Chapter 6 Maintaining State

    1. Introduction

    2. Maintaining Information Needed by All Users of an Application

    3. Maintaining Information about a User Throughout a Session

    4. Preserving Information Between Postbacks

    5. Preserving Information Across Multiple Requests for a Page

  7. Chapter 7 Error Handling

    1. Introduction

    2. Handling Errors at the Method Level

    3. Handling Errors at the Page Level

    4. Handling Errors at the Application Level

    5. Displaying User-Friendly Error Messages

  8. Chapter 8 Security

    1. Introduction

    2. Restricting Access to All Application Pages

    3. Restricting Access to Selected Application Pages

    4. Restricting Access to Application Pages by Role

    5. Using Windows Authentication

  9. Chapter 9 Configuration

    1. Introduction

    2. Overriding Default HTTP Runtime Parameters in web.config

    3. Adding Custom Application Settings in web.config

    4. Displaying Custom Error Messages

    5. Maintaining Session State Across Multiple Web Servers

    6. Accessing Other web.config Configuration Elements

    7. Adding Your Own Configuration Elements to web.config

  10. Chapter 10 Tracing and Debugging

    1. Introduction

    2. Uncovering Page-Level Problems

    3. Uncovering Problems Application Wide

    4. Pinpointing the Cause of an Exception

    5. Uncovering Problems Within Web Application Components

    6. Uncovering Problems Within Dual-Use Components

    7. Writing Trace Data to the Event Log with Controllable Levels

    8. Using a Breakpoint to Stop Execution of an Application When a Condition Is Met

    9. Stress Testing a Web Application or Service

  11. Chapter 11 Web Services

    1. Introduction

    2. Creating a Web Service

    3. Consuming a Web Service

    4. Creating a Web Service That Returns a Custom Object

    5. Setting the URL of a Web Service at Runtime

  12. Chapter 12 Dynamic Images

    1. Introduction

    2. Drawing Button Images on the Fly

    3. Creating Bar Charts on the Fly

    4. Displaying Images Stored in a Database

    5. Displaying Thumbnail Images

  13. Chapter 13 Caching

    1. Introduction

    2. Caching Pages

    3. Caching Pages Based on Query String Parameter Values

    4. Caching Pages Based on Browser Type and Version

    5. Caching Pages Based on Developer-Defined Custom Strings

    6. Caching User Controls

    7. Caching Application Data

  14. Chapter 14 Internationalization

    1. Introduction

    2. Localizing Request/Response Encoding

    3. Providing Multiple Language Support

    4. Overriding Currency Formatting

  15. Chapter 15 File Operations

    1. Introduction

    2. Downloading a File from the Web Server

    3. Uploading a File to the Web Server

    4. Processing an Uploaded File Without Storing It on the Filesystem

    5. Storing the Contents of an Uploaded File in a Database

  16. Chapter 16 Performance

    1. Introduction

    2. Reducing Page Size by Selectively Disabling the ViewState

    3. Speeding up String Concatenation with a StringBuilder

    4. Speeding Up Read-Only Data Access

    5. Speeding Up Data Access to a SQL Server Database Using the SQL Provider

  17. Chapter 17 HTTP Handlers

    1. Introduction

    2. Creating a Reusable Image Handler

    3. Creating a File Download Handler

  18. Chapter 18 Assorted Tips

    1. Introduction

    2. Accessing HTTP-Specific Information from Within a Class

    3. Executing External Applications

    4. Transforming XML to HTML

    5. Determining the User's Browser Type

    6. Dynamically Creating Browser-Specific Stylesheets

    7. Saving and Reusing HTML Output

    8. Sending Mail

    9. Creating and Using Page Templates

  1. Colophon

View Full Table of Contents
Product Details
Title:
ASP.NET Cookbook
By:
Michael A Kittel, Geoffrey T. LeBlond
Publisher:
O'Reilly Media
Formats:
  • Print
  • Safari Books Online
Print Release:
August 2004
Pages:
848
Print ISBN:
978-0-596-00378-4
| ISBN 10:
0-596-00378-1
Customer Reviews
About the Author
  1. Michael A Kittel

    Michael Kittel has nearly 30 years experience in the software industry. He has been working with Microsoft technologies for more than 10 years and with ASP.NET since the alpha release of 1.0. He has been the system architect and led the development of applications for Lexis-Nexis, Plow & Hearth, ReturnBuy, and many others. Michael has a Microsoft Certified Solutions Developer certification and is currently a senior consultant at Dominion Digital, Inc. (www.dominiondigital.com), a firm that specializes in helping companies envision and achieve maximum business value from investments in technology.

    View Michael A Kittel's full profile page.

Colophon

Our look is the result of reader comments, our own experimentation, and feedback from distribution channels. Distinctive covers complement our distinctive approach to technical topics, breathing personality and life into potentially dry subjects. The animal on the cover of ASP.NET Cookbook is a thorny woodcock (Murex pecten). This carnivorous marine snail is indigenous to the Indo-Pacific region of the world and is commonly found in the shallow waters off the coast of Japan's sandy beaches. Averaging 13 centimeters in length, the woodcock's elongated shell contains a stunning spine of thorns, and at first glance might be mistaken for the skeleton of a fish. While scientists are uncertain of the evolutionary advantages of this shell structure, some theorize that it serves to help ward off fish and other predators. They also believe the woodcock's needles may prevent the creature from being lodged in the soft sand and mud of its habitat.

The thorny woodcock has been immortalized in Western folklore, in which it is commonly referred to as the Venus comb or mermaid's comb. The animal's shell of needles is mythically purported to be the definitive fine-toothed comb, ideally suited for brushing even the delicate hair of a goddess.

Shell collectors are also drawn to the unique beauty of the thorny woodcock. Although its shell is not particularly rare, it is quite fragile, and a woodcock with a fully intact skeleton of thorns is a highly prized specimen for the distinguished conchologist. Genevieve d'Entremont was the production editor and proofreader for ASP.NET Cookbook. Nancy Reinhardt was the copyeditor. Colleen Gorman and Claire Cloutier provided quality control. James Quill and Sanders Kleinfeld provided production assistance. Johnna VanHoose Dinse wrote the index.

Emma Colby designed the cover of this book, based on a series design by Edie Freedman. The cover image is a 19th-century engraving from Animate Creation. Clay Fernald produced the cover layout with QuarkXPress 4.1 using Adobe's ITC Garamond font.

Melanie Wang designed the interior layout, based on a series design by David Futato. This book was converted by Andrew Savikas and Julie Hawks to FrameMaker 5.5.6 with a format conversion tool created by Erik Ray, Jason McIntosh, Neil Walls, and Mike Sierra that uses Perl and XML technologies. The text font is Linotype Birka; the heading font is Adobe Myriad Condensed; and the code font is LucasFont's TheSans Mono Condensed. The illustrations that appear in the book were produced by Robert Romano and Jessamyn Read using Macromedia FreeHand 9 and Adobe Photoshop 6. The tip and warning icons were drawn by Christopher Bing. This colophon was written by Sanders Kleinfeld.

  • Book cover of ASP.NET Cookbook