Click here to Skip to main content
15,946,988 members
Please Sign up or sign in to vote.
1.00/5 (1 vote)
See more:
Dear Friends,

I have a problem regarding the asp.net datagridview.

I have a child grid within a parent grid. I have a button outside means on the form on the click o f which i have to add a blank datarow but as i am not able to find the child grid within the parent grid, I am not able to add the blank row.

Please help me find the child grid.

Thanks

Varun Sareen
Posted
Comments
Sandeep Mewara 18-Apr-11 11:24am    
Shared the code that you have tried.

gdvparentgrid.findcontrol("chilgridId");
 
Share this answer
 
Have a look at this link Accessing the different controls inside a GridView control[^]Here it is iterating through all the rows of the GridView control using the GridViewRow object and then using FindControl method to get the control.You can replace the code with your child gridview.
 
Share this answer
 

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