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

ScrollIntoView with RowDetails

2 Answers 177 Views
GridView
This is a migrated thread and some comments may be shown as answers.
Sergej Mertens
Top achievements
Rank 1
Sergej Mertens asked on 17 Feb 2011, 09:24 AM
Hi,

I have a GridView with RowDetailsVisibilityMode set to "VisibleWhenSelected" and a RowDetailsTemplate in which I put a DataTemplate with a Grid panel. In this Grid I have several Buttons for row actions.

Whenever I select a line in code and then use ScrollIntoView for the selected Item (which is mostly not in view and at the bottom of the list), the row is indeed scrolled into view. But not the complete row details (which are expanded due to RowDetailsVisibilityMode ); only the "upper" part (the selected line) is visible and not my buttons. They are still down below.

I expect ScrollIntoView brings the complete line including row details into view.

Tested with RadControls 2010.3.1110.40

Greetings,
Daniel

2 Answers, 1 is accepted

Sort by
0
Accepted
Rossen Hristov
Telerik team
answered on 17 Feb 2011, 11:06 AM
Hi Daniel Schilling,

We have recently reworked the entire ScrollIntoView logic (which uses a lot of heuristics to calculate something that cannot be actually calculated exactly, since row details height might be totally arbitrary each time they are expanded).

Could you please try your project with the Latest Internal Build binaries.

Have in mind though, that when row details are present, the ScrollIntoViewAsync method is not *guaranteed* to work, because the row details height cannot be know in advance. Consequently the math cannot be done in advance, since we have an unknown variable. Thus we are doing a kind of Newton approximation in order to *try* to locate the row being requested. This works most of the times, but it is not guaranteed to work 100% of the time due to the fact that we have to calculate vertical scroll offsets without knowing all the number.

Anyway, could you please give your project a spin with the Latest Internal Build binaries and see how it goes.

Regards,
Ross
the Telerik team
0
Sergej Mertens
Top achievements
Rank 1
answered on 21 Feb 2011, 11:12 AM
Hi Ross,

thanks for your very fast reply. It works now as expected!

Greetings,
Daniel
Tags
GridView
Asked by
Sergej Mertens
Top achievements
Rank 1
Answers by
Rossen Hristov
Telerik team
Sergej Mertens
Top achievements
Rank 1
Share this question
or