AbstractCreating an ASP.NET 2.0 web form that you can use to edit an Access database can be done without writing any code. Simply drop two web server controls into your web form and set a few properties, and you're done. Wow! That's rapid development.

[ Download Code ]First, we are going to need an Access database table that defines at least one primary key. The primary key is needed for making changes to the table. If you were just going to display the database table, you would not need the primary key. Listing 1 shows the database table schema for a list of authors.

Second, we need to create a new web form. For this I used Visual Web Developer 2005 Express Edition. Now, drag and drop an AccessDataSource control and a GridView control onto your web form. These two controls are both new in version 2.0 of the .NET Framework, and I know they will save developers a lot of time. Now we just need to set a few properties.

That's all there is! You now have a web form that can edit and delete rows in an Access database table, all of this without writing a single line of code. Listing 2 shows the web form. Notice the absence of code. Screen Shot 1 shows the web form in action.

There is only one piece missing--the ability to add rows to our Access table. The only problem is that GridView will not allow you to add rows. Not to worry, we can still accomplish this without writing code. Let's see how.