Posted 2/19/2007 3:42:03 PM | | | | I have got a question. What I am trying to do is to use the datagrid object to view some external data. I have a lookup and header grid and a detail grid each calling a different griddata page. This seems to work fine as far as getting the data from my external data source, so I want to move on to adding the functionality I'm looking for. Namely: I want to pass in the customerNumber selected in the lookup to filter the header grid dataset. When an item in the header grid is selected I want to pass the projectID field to filter the detail grid dataset. My handydandy ASP book had a few options for doing this; none of which I could get to work. Could anyone point me in the right direction as to the best way to implement this. Thanks
Debra |
| Posted 2/19/2007 11:05:16 PM | | | I want to pass in the customerNumber selected in the lookup to filter the header grid dataset. There is a sample called "Multiple Lookups" included in the SDK that I demonstrate during my conference that does something very similar: when a value is selected in a lookup control, a second lookup is filtered based on the user's selection. In your case, the second control is a grid instead of a second lookup but what you are trying to do is conceptually very similar. When an item in the header grid is selected I want to pass the projectID field to filter the detail grid dataset. There is a click event in the top grid that you can override in order to be notified when the user makes a selection. One of the parameters passed to your event handler is the unique identifier of the record selected by the user which you can use to filter the second grid.
|
| Posted 2/20/2007 1:03:38 AM | | | | to make it even easier for you, I created a new sample to demonstrate how to do it: http://www.c360.com/Forums/Topic1187-39-1.aspx Here's what this new sample demonstrates: - The sample page includes 3 controls: one lookup and 2 grids.
- The lookup allows you to select a territory
- When you select a territory, the first grid refreshes and shows the accounts in the selected territory
- When you select an account in this grid, the second grid refreshes and shows the employees of the selected account
Let me know if this is what you were looking for.
|
| |
|