Gridview inside gridview problem

V

Vik

I have a gridview inside a gridview.The child gridview has a SQLDataSource
with one parameter. I assign a value to this parameter in a RowDataBound
event procedure of the parent gridview:
string strIncID = ((LinkButton)e.Row.Cells[0].Controls[1]).Text;
sdsPersonExtV.SelectParameters["IncidentID"].DefaultValue = strIncID;

When debugging, I see that the parameter gets the correct values for every
row. When a page is displayed, the child gridview has the same values in all
the rows of the parent gridview. These values correspond to the last row of
the parent gridview.

What is wrong here?

Thanks.

Victor
 
V

Vik

The problem was that the SQLDataSource was placed outside of the gridview.
It should be in the same template as the child gridview.

Another problem now is that I cannot set the width of the columns for the
child gridview. The columns have the different widths in the different rows.

Thanks.

Victor
 

Ask a Question

Want to reply to this thread or ask your own question?

You'll need to choose a username for the site, which only take a couple of moments. After that, you can post your question and our members will help you out.

Ask a Question

Similar Threads


Members online

Forum statistics

Threads
473,744
Messages
2,569,483
Members
44,903
Latest member
orderPeak8CBDGummies

Latest Threads

Top