July 2007 - Posts

July's Toolbox Column Online
07 July 07 02:08 PM | Scott Mitchell

My Toolbox column in the July 2007 issue of MSDN Magazine is avaiable online. The July issue examines three products:

  • ANTS Profiler - quickly and easily find performance and memory bottlenecks in your .NET applications with this helpful tool.
  • Simian - duplicate source code can happen when developers cut and paste code. Such repetitious code is dangerous because if there is a bug in the duplicated code or if the business logic is changed, problems will arise unless all duplications of the code are appropriately modified. Simian can efficiently search through millions of lines of source code and alert you if it finds any duplicate blocks of code.
  • Pixie - a free, light-weight color picker.

This month's issue reviewed Foundations of Security, by Neil Daswani et al. Here is an excerpt from the review:

Security requires planning and domain knowledge and its results are not easily measurable. Furthermore, since security spans physical, technological, and policy levels, it is easy for a developer to bury her head in the sand and assume someone else will implement or has implemented the necessary security precautions. Such attitudes, however, are an invitation to disaster. Security is an important aspect of any application and all developers should have at least a cursory understanding of key security concepts, potential attack vectors, and techniques for protecting against common threats. Foundations of Security: What Every Programmer Needs to Know (Apress, 2007), ... provides a solid overview of security fundamentals at a level appropriate for developers who may have little to no background in security.

As always, if you have any suggestions for products or books to review for the Toolbox column, please send them into toolsmm@microsoft.com.

Five New "Working with Data in ASP.NET 2.0" Tutorials Available - SiteMaps and Batched Data
01 July 07 07:51 AM | Scott Mitchell

My Working with Data in ASP.NET 2.0 tutorial series has been updated with five new tutorials: one on building database-driven site maps and four on working with batched data.

The site map feature introduced in ASP.NET 2.0 allows developers to logically arrange a web application's pages into a hierarchy. This hierarchy can then be accessed programmatically through the SiteMap class in the .NET Framework or rendered visually through the Menu, TreeView, and SiteMapPath controls. .NET ships with a site map implementation that serializes the site map to an XML file. Since the site map framework was designed using the provider model, developers can easily plug in their own serialization implementations. (For more on ASP.NET 2.0's site map feature, see Examining ASP.NET 2.0's Site Navigation.) Building a Custom Data-Driven SiteMap Provider [VB | C#] looks at how to create a site map provider that constructs the site map based on data pulled from the application architecture.

The remaining four tutorials look at working with batched data. By default, the GridView is designed to modify data one record at a time. The built-in Delete and Edit buttons, for example, allow for one record to be deleted or updated. This can result in a lot of pointing and clicking when you need to delete or edit multiple records. The four tutorials on working with batched data examine important considerations and illustrate how to customize the data Web controls to create a user interface conducive to batch deletes, updates, and inserts:

  • Wrapping Database Modifications within a Transaction [VB | C#] - looks at how to wrap a series of database modifications within the scope of a transaction. Transactions guarantee atomicity, ensuring that either all of the batched modifications will succeed or none of them will.
  • Batch Updating [VB | C#] - examines turning a GridView into a fully-editable GridView, where all rows can be edited at once.
  • Batch Deleting [VB | C#] - shows how to add a series of checkboxes to a GridView to enable multiple records to be deleted at the click of a button.
  • Batch Inserting [VB | C#] - explores a user interface for quickly inserting multiple records.

Like the previous tutorials in the series, all tutorials are available in C# and VB, include the complete code download as a self-extracting ZIP, and are available in PDF format.

Happy Programming!

Filed under:
More Posts


My Books

  • Teach Yourself ASP.NET 4 in 24 Hours
  • Teach Yourself ASP.NET 3.5 in 24 Hours
  • Teach Yourself ASP.NET 2.0 in 24 Hours
  • ASP.NET Data Web Controls Kick Start
  • ASP.NET: Tips, Tutorials, and Code
  • Designing Active Server Pages
  • Teach Yourself Active Server Pages 3.0 in 21 Days

I am a Microsoft MVP for ASP.NET.

I am an ASPInsider.