Opening Popup Window in ASP.NET to Search, Select, and Position on a Specific Record in a DataGrid.
Posted on 2005-04-17
I have an ASP.NET application written in VB.NET. The main page lists customers via a datagrid that is populated from a SQL Server 2000 database. The dagagrid allows paging (10 customers/page) and sorting using the builtin capabilities of the datagrid. Currently there are approcimately 250 customers that get returned and placed in a dataset. The dataset is used as the datasource for the datagrid on the main page.
Recently, the user asked for a popup window to allow them to search via the lastname. They want the popup window as follows WITHOUT requiring a postback to the server. They want to use the customer data that has been returned and that is in the dataset. Here is the scenario:
1. From the main window, click on an image control to open up the search window as a modal dialog (this app only runs on IE)
2. When the popup opens, enter a search string to find the customer on lastname.
3. Searching is from left to right based on the number of characters entered.
4. Search on the lastname in the dataset displaying the results in a datagrid that is also in the popup window.
5. Vertical scrolling is required in the popup window WITHOUT paging.
6. Select the desired record from the popup window datagrid and close the popup window.
7. Return the record selected and select the record in the datagrid on the main page.
8. If the record selected isn't visible in the current page, go to the page where it is located and make it the current page.
9. DO NOT change the sort sequence of the main datagrid.
I'm OK with all items except 4, 6, 7, and 8. Any ideas on how to complete this?