Anyname Donotcare
Anyname Donotcare

Reputation: 11393

GridView Customization

I have a grid view with more than one control (ie. a DropDownList and a TextBox)

How can I bind the DropDownList in the gridview and how do I insert an add button in the footer of the gridview

I have found a few ways to do this but they are confusing and I am not sure about the performance of them.

Upvotes: 0

Views: 1319

Answers (3)

NakedBrunch
NakedBrunch

Reputation: 49413

Take a look here: Adding an insert row to GridView.

It provides a full code sample that is easy to follow. In terms of performance, adding a row will require a postback but you can wrap your GridView in an UpdatePanel and very easily have a seemingly AJAXified GridView.

Upvotes: 1

Fadrian Sudaman
Fadrian Sudaman

Reputation: 6465

If you want a flexible control of the layout and still get all the power of GridView, I suggest that you look into ListView. You have control over the template for layout, footer, item and etc. which sounds like what you need. Here is the comparison between ListView, GridView and others.

http://weblogs.asp.net/anasghanem/archive/2008/09/06/comparing-listview-with-gridview-datalist-and-repeater.aspx

Upvotes: 2

Rev
Rev

Reputation: 2265

you can keep searching in Google and find good example's.

These links may help you:

Upvotes: 1

Related Questions