Groups | Blog | Home
all groups > asp.net datagrid control > october 2006 >

asp.net datagrid control : dynamically add hyperlinks and buttons to a datagrid


Richard Jonker
10/2/2006 7:53:37 PM
Hi,

I'm developing a webpage with a datagrid. The data is retrieved from a
database and via a dataset dynamically binded to the datagrid. So, the
fields from the query are defining the displayed columns.

How can I add special columns like buttons and hyperlinks dynamically to the
columns? And how to add events?
When using MS Studio Developer you can add these columns via the property
builder. In that case the first colums contains the buttons, I want
them in the last columns.

Any ideas ?

Many thanks in advance

Richard


Richard Jonker
10/2/2006 11:44:06 PM
Ok, I just figured out (after 3 days) to use the EditCommandColumn. I works
really fine. But how can I specify that it should be in the last columns
instead of the first columns?


Richard


"Richard Jonker" <internet@jnkr.eu> schreef in bericht
news:45215220$0$2021$ba620dc5@text.nova.planet.nl...
[quoted text, click to view]

Niraj Ranka
10/3/2006 12:00:00 AM
Hello,

Just set the sequence of columns in datagrid.

Also u can use template columns too.

Regards--
Niraj Ranka
http://dotnetpub.blogspot.com/
[quoted text, click to view]

AddThis Social Bookmark Button