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

RadPanorama ScrollBar Error

1 Answer 32 Views
ScrollBar
This is a migrated thread and some comments may be shown as answers.
Sherlock
Top achievements
Rank 1
Sherlock asked on 08 Nov 2013, 11:33 PM
Hi
I added a RadPanorama to my form.
Now what I want is the ScrollBar, Be at the middle, not be at the top.
I mean I need my page to be at middle.

What I did is go to Element hierarchy editor, then from the left column, I selected RadScrollBarElement.
Then from right column, I set the Value to 50

This works fine in my Designer window, but when I run, it doesn't work.
Please see the attachment.

Would you please help me?

Thanks.



I should add that I tested RadHScrollBar and RadVScrollBar with the same way I explained, and they worked fine.
It seems there is bug in panorama scrollbar.

1 Answer, 1 is accepted

Sort by
0
Dess | Tech Support Engineer, Principal
Telerik team
answered on 13 Nov 2013, 05:02 PM
Hello Sherlock,

Thank you for contacting Telerik Support.

RadHScrollBar is an independent control and when you change the RadScrollBarElement.Value property, it is serialized in the designer as RadHScrollBar Value. When you make the same thing with the scroll bar inside some control, RadScrollBarElement is dependent on number of items and in this case we do not serialize scroll bar value in the designer file. That is why the appropriate approach to set RadScrollBarElement.Value is doing it in the form's constructor:
public Form1()
{
    InitializeComponent();
 
    radPanorama1.PanoramaElement.ScrollBar.Value =
        radPanorama1.PanoramaElement.ScrollBar.Maximum / 2;
}

I hope this information helps. Should you have further questions, I would be glad to help.

Regards,
Desislava
Telerik
TRY TELERIK'S NEWEST PRODUCT - EQATEC APPLICATION ANALYTICS for WINFORMS.
Learn what features your users use (or don't use) in your application. Know your audience. Target it better. Develop wisely.
Sign up for Free application insights >>
Tags
ScrollBar
Asked by
Sherlock
Top achievements
Rank 1
Answers by
Dess | Tech Support Engineer, Principal
Telerik team
Share this question
or