Master/Details display: can two Master lists feed the same Details control?
Hello,
I am trying to set up a Master-Details feature with two distinct lists of links on the "Master" side and one control on the "Details" side, all displaying on the same page. For example, the Master control(s) would display a list of links to item details, seperated into two sections:
Teachers
link1
link2
link3
Students
link1
link2
link3
...each of the links under both "Teachers" and "Students" would populate a single Details control with data appropriate to the selected link.
Right now I have a simple Master/Details on a single page using a single column gridview as the Master (<asp:ButtonField CommandName="Select" />) and a FormView control for Details. The Master Details relationship is handled declaratively with a <SelectParameters> in the Detail control's SQL Data Source. However, this arrangement only allows for a single column of Master links, i.e.:
Teachers & Students
link1
link2
link3
link4
link5
link6
I'm not sure how to solve this; is there any way to
1. have two Master controls feed to the same details control?
2. or perhaps have a Details control for each Master list, but swap visibility for each Detail control so it appears that there is only one Details control on the page?
3. or else have a Master control like a gridview or datalist display two sections of links, one on top of the other, each section with its own HeaderText, controlling the same Details control?
Thanks very much for any advice!
|