Itemupdating firing more than once in detailsview

When optimizing for these considerations, you might find that building data-bound applications by using the server controls in ASP.

The control provides a free table-based interface with one column for labels and one column for input fields.

You set the working mode of the Details View to Insert and go: Figure 1 shows the output you get.

The Details View control lacks a property to indicate the default value of an input field. You might think that the Details View control fires an event that, properly handled, gives you a chance to set the default value of input fields. More precisely, the Details View control doesn t fire a specific event that would let you do so.

However, in the long list of events fired by the Details View control, there s one that you can leverage to implement a little piece of logic to set default input values.

Let s say you need a Web page that collects data and populates a database.

By using the Details View control you save yourself a bunch of user interface stuff.

To complete the lessons in this chapter, you should be familiar with developing applications with Microsoft Visual Studio 2010 by using Microsoft Visual Basic or Microsoft Visual C#.

In addition, you should be comfortable with all of the following: REAL WORLD: Mike Snell Not all applications require developers to write custom, abstracted data layers and reusable frameworks.

The second lesson in this chapter demonstrates how you can bind to data to allow users to interact with it.

Tags: , ,