Getting IIS to work in Chapter 1
If you decide to buy this book, here are a few tips I discovered during my review.
Using IIS
IIS (Internet Information Server) is the name of Microsoft's web server. Murach correctly notes that you don't have to use IIS to develop a web site in VB.NET 2008 because the tools to develop and debug ASP.NET on a single machine are built in. IIS is included in Vista (Home Basic and Starter Editions only have basic functions and a few features aren't in Home Premium). The assignment for chapter 1 requires that you use IIS!
But when you do that using Vista, you might run into a hidden trap. Full disclosure: using very similar setups, I did but the author of the book didn't. In case you're unlucky like I was, here's how I got out of the trap.
Appendix C includes a few pages devoted to "virtual directories" and chapter 4 warns you to work within Visual Studio to avoid problems. You might want to read those parts of the book first before using IIS.
When you're trying to do the first exercise, one obvious choice for Vista users is to simply copy the downloadable files to a directory somewhere in "Documents" and use the book's instructions to create a virtual directory pointing to the physical path to the files. If you do this, you will probably run directly into two problems that create a hard error ("Cannot read configuration file due to insufficient permissions" and "HTTP Error 401.3: Unauthorized: Access is denied")
First, permissions need to be set for two entities:
- Users (<computer name>\Users)
- IIS_IUSRS (<computer name>\IIS_IUSRS)
Right click on the actual directory you set set up as a virtual directory, select "Properties" and then the "Security" tab. Click "Edit" and then "Add". In the "Enter the object names to select" box, enter "<computer name>\Users" (replace "<computer name>" with the name of your computer). Click "Check Names" and then click "OK". Select these permissions:
- Read & execute
- List folder contents
- Read
Repeat for the other entity, "<computer name>\IIS_IUSRS".
Second, the virtual directory must be "converted to an application" using the IIS Manager (directions to start IIS Manager are in the book). This "marks" the directory as an IIS application. In IIS Manager, right-click on the virtual directory and click "Convert To Application".
I found a few other small errors that Murach has confirmed. Murach has assured me that they will be fixed in the next printing.
On page 56, this statement appears:
"In most cases, client-side validation is done when the focus leaves an input control that has validators associated with it. That can happen when the user presses the Tab key to move to the next control or clicks another control to move the focus to that control. Validation is also done when the user clicks on a button that has its CausesValidation property set to True."
ASP RequiredFieldValidator validation isn't done when the focus leaves an input control however. This is explained correctly on page 250.
On page 117, the ASP.NET DropDownList control is misnamed as a "combo box". The terminology is correct in the figures 3-10 and 3-11 referenced at the same time. To be fair, Microsoft only uses this new name in ASP.NET. They use the old name in their other products.




