This is a migrated thread and some comments may be shown as answers.

Grid changing PageSize causes StackOverflowException

2 Answers 146 Views
Grid
This is a migrated thread and some comments may be shown as answers.
Christian
Top achievements
Rank 1
Christian asked on 20 Aug 2008, 10:07 AM
Hi,

i have a RadGrid on my ASPX Page. When i use the build in control to change the page size a System.StackOverflowException is thrown in the PageSizeChanged Event during assign the new page size (grid.PageSize = e.NewPageSize. In debugging the the event is never left.

Can someone help me?


Christian

2 Answers, 1 is accepted

Sort by
0
Accepted
Nikita Gourme
Top achievements
Rank 1
answered on 22 Aug 2008, 01:29 PM
Do you use one of the advanced grid pagers to change the page size or do that explicitly inside the PageSizeChanged handler? If you perform this action both with the buit-in method and explicitly, the event may be raised in a loop since the page size is modified within the handler and the event is raised once again which forms a dead lock.

Nikita
0
Christian
Top achievements
Rank 1
answered on 22 Aug 2008, 02:00 PM
Hello Nikita

this was the problem. Thank you for your help.

Christian
Tags
Grid
Asked by
Christian
Top achievements
Rank 1
Answers by
Nikita Gourme
Top achievements
Rank 1
Christian
Top achievements
Rank 1
Share this question
or