Reputation: 4711
So I create plop two gridviews onto page, define BOTH their datasources in code behind :
protected void Page_Load(object sender, EventArgs e)
{
DataTable dt = Common_Users.GetUsersDataTable();
gvMaster.DataSource = dt;
gvMaster.DataBind();
gvDetail.DataSource = dt;
gvDetail.DataBind();
}
Then tell the Master gv to use a details row and I open the detailsRow template and (as devexpress says to do) I put the DETAIL gv inside that template.
However, NOW my page_load can no longer fine gvDetail ... How do I continue to call gvDetail NOW that its inside of gvMaster?
Upvotes: 1
Views: 14459
Reputation: 9300
It is necessary to provide data for detail ASPxGridView by handling its BeforePerformDataSelect event. Check the http://www.devexpress.com/Support/Center/e/E257.aspx example to see this approach in action.
Upvotes: 1