V
Verdict
Hi
My form includes a dropdown list(DL) that represent types of customers and
submit button(BTN).
When I press the BTN it runs a query related to the selected DL and fills a
datagrid that supports pagination.
The problem is that if I go to page 15 for example and then replace my DL to
another type and submit again, if the other type doesn't have 15 pages as
well, I get error message:
Invalid CurrentPageIndex value. It must be >= 0 and < the PageCount
I tried to reset my datagrid for every BTN pressing by using :
dgSearch.CurrentPageIndex = 0
dgSearch.DataBind()
Any help is appreciated!
My form includes a dropdown list(DL) that represent types of customers and
submit button(BTN).
When I press the BTN it runs a query related to the selected DL and fills a
datagrid that supports pagination.
The problem is that if I go to page 15 for example and then replace my DL to
another type and submit again, if the other type doesn't have 15 pages as
well, I get error message:
Invalid CurrentPageIndex value. It must be >= 0 and < the PageCount
I tried to reset my datagrid for every BTN pressing by using :
dgSearch.CurrentPageIndex = 0
dgSearch.DataBind()
Any help is appreciated!