T
thegame
Filling One DataGrid Based on Selection from Another DataGrid - Both in
Separate User Controls
Hello, I have an interesting dilemma.
I have an ASPX page with two user controls (two ASCXs). Both ASCXs have
DataGrids on them. The first user control's DataGrid is populated from our
database on page load. The DataGrid also has a Select LinkButton.
What I need is for the selected row in the first DataGrid to be used as
input to another query that dynamically fills the second DataGrid. This
second DataGrid is in the second user control. I'm having trouble doing
this. Any suggestions????
In my first user control, I have the item command event for the first
DataGrid as such:
private void DataGrid1_ItemCommand(object source, DataGridCommandEventArgs
e)
{
if (e.CommandName == "SelectMasterReport")
{
// get the selected value needed using e.Item.Cells[3].Text
// code here to populate the second DataGrid?????
}
}
Thanks in advance for any help!
Separate User Controls
Hello, I have an interesting dilemma.
I have an ASPX page with two user controls (two ASCXs). Both ASCXs have
DataGrids on them. The first user control's DataGrid is populated from our
database on page load. The DataGrid also has a Select LinkButton.
What I need is for the selected row in the first DataGrid to be used as
input to another query that dynamically fills the second DataGrid. This
second DataGrid is in the second user control. I'm having trouble doing
this. Any suggestions????
In my first user control, I have the item command event for the first
DataGrid as such:
private void DataGrid1_ItemCommand(object source, DataGridCommandEventArgs
e)
{
if (e.CommandName == "SelectMasterReport")
{
// get the selected value needed using e.Item.Cells[3].Text
// code here to populate the second DataGrid?????
}
}
Thanks in advance for any help!