Click here to Skip to main content
15,922,533 members
Please Sign up or sign in to vote.
3.00/5 (1 vote)
See more:
How to add events for dynamic grid view?

Share this answer
Below is the sample code snippet that will do your work. You have to make sure where are you adding the control and also need to add event handler to peroform operation like RowDataBound, Edit, delete etc based on your requirments.

GridView gridView = new GridView();
    gridView.ID = "gridViewDynamic";
    gridView.DataSource = mydatasource;
Share this answer
Abhijit Jana 30-Jan-11 23:57pm    
I guess I missunderstood the question. OP was looking for Adding Event. I will update it soon !

This content, along with any associated source code and files, is licensed under The Code Project Open License (CPOL)

CodeProject, 20 Bay Street, 11th Floor Toronto, Ontario, Canada M5J 2N8 +1 (416) 849-8900