I want to have a datagrid that is just one column of group names (say from
qryGroups)

When someone clicks on a group name (ie clicks in that 'cell' or the column
could be a hyperlink column... whatever is best), i want the datagrid to then
display results from qrySubgroups, but filter it for only those that have the
column intGroup equal to the intGroup value from the one they clicked from
qryGroups

ie
qryGroups has:

intGroup GroupName
1 Accounting
2 Orders
3 Service


qrySubgroups has

intGroup SubGroupName
1 Taxes
1 Booked Revenue
2 Customers
3 Maintenance
3 Repairs


So there are Taxes and Booked Rev as subgroups of Accounting

so the original dataset will display:

Accounting
Orders
Service

when the user clicks on Accounting, it should then display:

Taxes
Booked Revenue


how do i best do this?

can i just put both tables (qryGroups, qrySubgroups) into the dataset that
the table runs off of, then when they click on it, have it change from using
dataset1.qryGroups to dataset1.qrySubgroups and have it filter by
qryGroups.intGroup ?

or maybe the original cells are hyperlinks and they open subgroups.aspx and
pass the value of the group (intGroup) and then the dataset on that page runs
off of that value (filters by it?)

or maybe some easier or other way i'm not thinking of!

any help!?!?

Re: click on datagrid item, display new datagrid based on that click by Sahil

Sahil
Fri Oct 22 14:40:51 CDT 2004

Your solution is right here

http://www.asp.net/reportsstarterkit/SourceViewer/srcview.aspx?path=drilldown.src&file=drilldown&rows=5

Look at the "live version" link at the top. He uses a datalist, but the
concepts are similar :)

--
- Sahil Malik
http://www.dotnetjunkies.com/weblog/sahilmalik
Please reply to the newsgroups instead of email so everyone can benefit from
your reply.


"Nicholasp27" <Nicholasp27@discussions.microsoft.com> wrote in message
news:829F5FA3-0E90-4F53-BBF2-C3F69AE7EEAD@microsoft.com...
> I want to have a datagrid that is just one column of group names (say from
> qryGroups)
>
> When someone clicks on a group name (ie clicks in that 'cell' or the
column
> could be a hyperlink column... whatever is best), i want the datagrid to
then
> display results from qrySubgroups, but filter it for only those that have
the
> column intGroup equal to the intGroup value from the one they clicked from
> qryGroups
>
> ie
> qryGroups has:
>
> intGroup GroupName
> 1 Accounting
> 2 Orders
> 3 Service
>
>
> qrySubgroups has
>
> intGroup SubGroupName
> 1 Taxes
> 1 Booked Revenue
> 2 Customers
> 3 Maintenance
> 3 Repairs
>
>
> So there are Taxes and Booked Rev as subgroups of Accounting
>
> so the original dataset will display:
>
> Accounting
> Orders
> Service
>
> when the user clicks on Accounting, it should then display:
>
> Taxes
> Booked Revenue
>
>
> how do i best do this?
>
> can i just put both tables (qryGroups, qrySubgroups) into the dataset that
> the table runs off of, then when they click on it, have it change from
using
> dataset1.qryGroups to dataset1.qrySubgroups and have it filter by
> qryGroups.intGroup ?
>
> or maybe the original cells are hyperlinks and they open subgroups.aspx
and
> pass the value of the group (intGroup) and then the dataset on that page
runs
> off of that value (filters by it?)
>
> or maybe some easier or other way i'm not thinking of!
>
> any help!?!?