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

Using multiple CollapsiblePanel with automatic positioning

1 Answer 259 Views
CollapsiblePanel
This is a migrated thread and some comments may be shown as answers.
HMPSOLBB
Top achievements
Rank 1
HMPSOLBB asked on 24 Jun 2014, 10:43 AM
Hi,

I want to use multiple CollapsiblePanel on a form, all of them are loaded collapsed. The ExpandDirection is "down". If I open the first one I want to second (and also the others) to move down, starting below the first CollapsiblePanel. What is the best way to do this? Either witch CollapsiblePanel is open, the folowing have to start below of opened one.

Thanks!

Oliver

1 Answer, 1 is accepted

Sort by
0
Stefan
Telerik team
answered on 26 Jun 2014, 11:35 AM
Hello Oliver,

Thank you for writing.

To do that, once you expand the first panel, you need to check its size and according to its new size, set the Location of the rest of the panels i.e if you have three panels, all collapsed with height 40 px. The first is located at 0,40, the second at 0,80, the third at 0,120. Once you expand the first, check its size (let's say 140), deduct the initial panel size (140 - 40) and add the difference to the Y location of the other panels i.e. second panel location should be 0,140 and third panel location should be 0,180.

I hope that you find this information useful.

Regards,
Stefan
Telerik
 
Check out Telerik Analytics, the service which allows developers to discover app usage patterns, analyze user data, log exceptions, solve problems and profile application performance at run time. Watch the videos and start improving your app based on facts, not hunches.
 
Tags
CollapsiblePanel
Asked by
HMPSOLBB
Top achievements
Rank 1
Answers by
Stefan
Telerik team
Share this question
or