This book is written by famous authors and a program manager of the Microsoft ASP.NET Team, which ensures the quality of this book is remarkably high. A lot of buzz has been generated about ASP.NET “Whidbey” since it was first publicly introduced during the Professional Developers Conference in October of 2003. However, this technology is still in its alpha, or technical preview, release, and everything is subject to change until the final release. The reader of this book is expected to be familiar with ASP.NET 1.*, having intermediate level or above experience is recommended.
Chapter 1: An Introduction to ASP.NET 2.0
This chapter introduces the new features available in ASP.NET v2.0 in an easy to read format. This chapter highlights the attractive features of ASP.NET v2.0 accompanied by small code snippets and screen shots at a glance. The whole chapter is written in short paragraph and bullet point format. Nothing is detailed, but like a trailer of an upcoming film, this chapter can be treated as an extended version of the table of contents.
Chapter 2: Tools and Architecture
This chapter covers the features and ease of the coming version of Visual Studio .NET (so called VS.NET Whidbey), including the visual enhancement of master pages, toolbox, database connection and manipulation, etc. This chapter mentions the architecture of the new file and folder hierarchy and also describes file dependency, build order, and compilation life cycle, which is supposed to be the most interesting topic for ASP.NET developers.
However, the introduction for dynamic compilation, pre-compilation (in-place and deployment) and compilation API at the end of this chapter are relatively less informative--at least one to two pages more should be added as this topic is obviously one of the significant improvements in the next version of ASP.NET. This chapter is most likely a compliment to Chapter 1, so readers are recommended to read these two chapters consecutively.
Chapter 3: Data Source Controls and Data Binding
This chapter introduces the brand new DataSourceControl, including its characteristics, properties, and attributes. This chapter covers the new mobile device support feature in ASP.NET v2.0 and the adaptive rendering of summary data in mobile devices. This chapter also mentions the ability and advantages of caching and cache invalidation of the DataSourceControl as well as how to apply it in 2- or n-tier data access architecture, but the authors could talk a bit more about these features as it is one of the most exciting features of the DataSourceControl. This chapter somehow reminds me of a summary of MSDN documentation with a limited number of code snippets.
Chapter 4: The GridView and DetailsView Controls
This chapter examines two new list controls in ASP.NET v2.0 – GridView and DetailsView. The new features, abilities, and relationship between these two controls are covered in detail. A couple of long-awaited features were added and discussed, for instance, multiple fields for DataKeys, the CheckBoxField column, easy implementation of master-detail data, data binding with DataSourceControl, and how to present your data on mobile devices by writing code once. This chapter teaches readers how to prepare a data driven web application with the use of the new data source and data-bound controls using up to 70% less code.
Chapter 5: Master Pages and Navigation
The first section of this chapter introduces a new concept of master pages, as well as the ContentPlaceHolder and Content controls, and it explains how the master pages work with the use of a couple of diagrams. The authors show a useful technique named nested master pages. For example, developers can create a core (parent) master page file for the corporation and then create n x departmental (child) master page(s), such that any web page created per department not only has a common layout of the corporation but also has a consistent layout per department. At the end of this section, the authors mention how to configure master pages in page level, global level, and target on specific devices.
The next section mentions the new architecture of site navigation in ASP.NET v2.0. A sample of a site map configuration file and examples were used to explain the SiteMapDataSource. Again, a lot of MSDN-like tables are applied, as usual, in order to show the methods, properties, and attributes of SiteMapPath and SiteMapDataSource. The authors show how to access the site map at runtime at the end of this section, which is very interesting even you are not using a SiteMapPath control.
Chapter 6: Security
This chapter covers two new building blocks in ASP.NET v2.0, Membership and Role Manager, and provides a fast walk on the visual Web Administration Tool. The first section mentions the primary use of the Membership API – creditential validation – and illustrates several new static methods by showing a few small and easy to read code snippets.
Later, the authors introduce a couple of new security server controls, such as LoginView, LoginStatus, and PasswordRecovery by showing a few of small and easy-to-read code snippets.
The last topic in the first section is the Role Manager. The configuration and basic operations of this building block were covered pretty well by showing a few code snippets. Note that there’re many small words printed at the bottom of the page referenced to the content; these are additional and useful information so readers should pay extra attention to these small words during reading. This section repeats the provider design pattern and raises a good point that Membership and Roles are not rigidly coupled, but they are designed to work together, that is, Membership and Roles can use different data storage and providers but they can work perfectly together if necessary.
The second section of this chapter is all about Web Administration Tool, but it is very brief and short, maybe due to the implementation of its features not being complete in the alpha release.
Chapter 7: Personalization and Themes
The title of this chapter is Personalization and Themes, where I think “Personalization and Provider Model” is somehow more appropriate. This chapter talks about the features of Personalization at first and mentions why they create this feature by explaining the design goal. One of the features that is worth notice is the strong type feature of personalization, which implement the same provider model such that it is independent of the personalization APIs. The author defines how to choose the right storage based on the size and scale of the environment as well.
This chapter contains the recommendations/tips by the ASP.NET team about the creation and use of data via the provider model. This chapter explains the features of provider design pattern, implementing IProvider interface and illustrating real world examples of the ASP.NET Forums custom personalization provider, accompanied by the ASP.NET team's background information concerning writing personalization providers.
This chapter also explains the configuration of the new “Data” folder, SQL Server, and permission issues related to ASP.NET and IIS 6.0, including the GUI-based utility to configure SQL Server to support various application services. This chapter compares and contrasts personalization and the existing session state management in terms of lifespan and retrieval of data, which may be a FAQ or most confusing section for existing ASP.NET developers.
Moreover, this chapter clarifies the meaning and difference of "theme" and "skin" and shows how to create and configure theme and skin files. It integrates the use of Personalization as stated in the beginning of this chapter.
More InformationI: http://www.asp.net/faq/AspNetAndIIS6.aspx
Chapter 8: Web Parts and the Portal Framework
This is the best and well-organized chapter throughout the book, which contains an appropriate number of screen shots and code, too. This chapter first highlights the compatibility of ASP.NET Whidbey Web Parts and other MS and third-party products, such as MS Office and SharePoint, as well as the relationship between Personalization and the Portal Framework.
After the introduction and definition of goal of the Portal Framework, a simple object structure for the Web Part Portal page is shown, covering the overall structure and concept, followed by the diagram. The author writes an overview of the Web Part Framework, that is that the Web Part Framework contains different “Zones,” and each “zone” contains various “Parts.”
Next, the author describes the functions and features of each “Part,” one-by-one and clearly. A simple Web Parts example page with screen shots and code were used to further explain each web part afterwards (14 pages long!).
Finally, this chapter shows how to work with Web parts programmatically, with lots of MSDN-like (or Wrox style) tables, and mentions the constructors, methods, properties, and styles of each class (12 pages).
Chapter 9: Pages, Posting, and Validation
This chapter first introduces one of the long-awaited features in ASP.NET--Cross Page Posting--and explains how to access source and target pages programmatically. It also discusses the consideration and comparison of different properties of the Page object and Server.Transfer method. Next, this chapter introduces the new BaseValidator control and two new properties come with this control.
This chapter introduces a new Wizard server control, including how to create it declaratively and write code to control the style / theme and working mechanism briefly. Despite the fact that creating user friendly URL-based web applications is a trend, and ASP.NET v2.0 has a built-in engine called URL Mapping, incorporating this function easily, this chapter talks about this new feature with a couple lines of code of the configuration section and a tip in using it with two pages only.
This chapter then introduces a couple of new client script features in brief and then focuses on a particular client script feature called Client Callbacks. It explains what it is, how it works, and shows it in action (Wrox style?). This section contains a comprehensive example to explain the new feature of Client Callback. Last but not the least, this chapter presents a table showing the new page and control life cycle.
Chapter 10: Mobile Device Support
This chapter recalls the current situation of developing web applications for mobile devices as in ASP.NET v1.* and introduces the mechanism and goal of adaptive rendering in v2.0, which is the working mechanism to target mobile devices in ASP.NET v2.0. This chapter uses a simple example to demonstrate the rendered output in mobile devices and configuration file in V2.0, and it has a pretty long section about a new control, the Pager control, which is actually used to split a page into smaller pieces so as to fit in the small screen of mobile devices. Different usage, properties, and events are covered as well. Finally, two more mobile controls, PhoneLink and SoftKeyLabel, are covered at the end of this chapter briefly.
Chapter 11: Caching
This chapter first mentions the use and logic of Caching in ASP.NET, that is, output caching and the caching API. Then the theory and command used for toggle database, table for SQL cache invalidation are covered briefly. A detailed discussion of the new SqlCacheDependency class and a step-by-step example explaining how it works are well explained. One of the values of this chapter is that it covers the next version of SQL Server “Yukon” database a little bit as well.
Chapter 12: Control Enhancement
This chapter summarizes the information and features of controls at the beginning and categorizes the controls into six sections. Each section uses a small paragraph with a couple of bulleted points with short description, while there are a few detailed examples, code snippets, and explanations when talking about the new controls such as BulletedList, FileUpload, DynamicImage, and ImageMap. The new Image Generate Service, which is a new Page type of .ASIX, is completely new but there are merely 2 pages introducing it.
Next, this chapter covers the changes and new associated elements and properties of the existing server controls, which is essentially useful for all ASP.NET v1.* developers for migration and understand the new server controls. At any rate, this chapter is well written and pretty nice; the structure is similar to Chapter 8 where lots of new features and functionalities were covered and the applications (adaptive rendering) in mobile devices/emulators are highlighted too. Later on, this chapter describes the Site / Page counter - its API, and its configuration. Finally, a short introduction of Web Resources was included.
Chapter 13: Configuration and Administration
This chapter explores a lot of configuration and administration topics. There is also a short paragraph explaining the management of Session State in ASP.NET v2.0. Different from the Web administration tool covered in Chapter 6, this section mainly describes the elements and attributes in an application- or machine-wide configuration.
This section is divided into two parts: 1) what has changed or been removed from existing elements, such as the change in section of HttpModule, HttpRuntime, and SessionState, and 2) the description of the brand new sections including the section of Anonymous Identification, Compiler, Caching, Membership and SiteCounter. All of them use a pattern of declaration and a table describing its attributes. It looks like reading an SDK document, but it is a bit better as the line of description abstracts the feature of each element.
Next, this chapter talks about Session State, and introduces the new Control State and its implementation when authoring custom controls. In addition to the traditional session state storage, it introduces the technique to create our own Session State modules as well. After all, this chapter mentions how to perform some administrative tasks programmatically by using the Management API and via the IIS Management Console interface.
This book contains all of the information that available in the technology preview of ASP.NET v2.0. Though this book is not printed in red with photos and reading this book seems like reading a SDK documentation, this is actually the feature of the “First Look” or “Preview” book and is the style of the authors. The binding and printing quality of this book are very good, font size is good enough for reading and the size of the book is compact.
Understanding the main goal of writing this book by using the alpha release of ASP.NET Whidbey, there are few examples or code snippets throughout the book, but it mainly focuses on the declaration, concepts, and configurations of ASP.NET v2.0 where proof of concept is provided in a relatively stable way. Moreover, many tips and tricks and working/internal details were covered too. That obviously can’t be found in other books unless the author himself is an insider of the ASP.NET Team. This is a great book if you have basic knowledge of ASP.NET and want to have a first taste on the next version of ASP.NET
Book Provider: Addison-Wesley Pub Co
Editor: Ian Castor Chow