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

PageView special behavior

5 Answers 144 Views
PageView
This is a migrated thread and some comments may be shown as answers.
DenisCL
Top achievements
Rank 1
DenisCL asked on 18 Jan 2011, 06:41 PM
Hello,

I come to you because I meet a special behavior with the Pageview with viewMode set at Explorer bar.

This code resize the pageview at the loading of the form in order to have no scroll and autosize the pageview following pages extanted or not
The main aim is to stop the number of extanded pages at 2. If 2 are extanded and you extand one more, it's cancelled.

I've uploaded an example solution on a private ftp. Please take it there:

Solution

Simply launch it, extand the first page, the second, then the 3rd.
You'll see the pages are displayed in a weird way, and this is occurring only if you cancel on the last Page.
(wrongDisplay.jpg attached)
if you collapse all, and extand 1, 3 then 2, 2 is correctly stopped and display is good. (goodDisplay.jpg attached)

Do you have any workaround for that? because it's really important in my application and tons of users are meeting this behavior.

Thanks a lot for your lights

Regards

5 Answers, 1 is accepted

Sort by
0
Accepted
Alexander
Telerik team
answered on 21 Jan 2011, 04:16 PM
Hello Denis,

Thank you for your question.

You can achieve your scenario using the SelectedPageChanging event of RadPageView. Before canceling the expanding of the page, you should cancel its selection. Please find attached to my response your updated project.

Do not hesitate to contact us again if you have additional questions.

Kind regards,
Alexander
the Telerik team
Q3’10 SP1 of RadControls for WinForms is available for download; also available is the Q1'11 Roadmap for Telerik Windows Forms controls.
0
DenisCL
Top achievements
Rank 1
answered on 25 Jan 2011, 01:58 PM
Hello,

Perfect it's working, thanks a lot.

I meet another special behavior from RadDropDownList. Last time I asked, someone answered to me it was an old bug and should be corrected in the last release. I'm using Q3 2010 and I've reproduced it in a simple solution you can get there: Here

Just open it, launch the application, scroll down the form to the groupbox with the RadDropDownList, open the dropdown and scroll up. You should get the same behavior as the capture.jpg screenshot attached

Any workaround for this?
0
Alexander
Telerik team
answered on 28 Jan 2011, 01:25 PM
Hello DenisCL,

Thank you for describing this issue and providing a sample project.

I confirm this issue exists in the latest version of the WinForms controls. It will be addressed in our next major release. Due to the nature of the issue I am not able to provide a workaround for it.

Please write back if you have more questions.

Best regards,
Alexander
the Telerik team
Q3’10 SP1 of RadControls for WinForms is available for download; also available is the Q1'11 Roadmap for Telerik Windows Forms controls.
0
DenisCL
Top achievements
Rank 1
answered on 15 Feb 2011, 02:27 PM
Hello,

I come back to you about the problem of resizing the RadPageView according to its pages expanded or collapsed.

In fact everything works fine if we change the RadPageViewPage we clicked (SelectedPagechanging)

But if we click on the same page for extanding then collapsing, this code is not called.

Do you see anyway, other than pageExpanding, to make the desired effect?
0
Alexander
Telerik team
answered on 17 Feb 2011, 09:54 AM
Hello Denis,

The solution I could offer you is to count the expanded RadPageView pages in the PageExpanding event handler. The code of the event handler will be:
private void radPageView1_PageExpanding(object sender, RadPageViewCancelEventArgs e)
{
    this._amountExpanded = 0;
    foreach (RadPageViewPage page in this.radPageView1.Pages)
    {
        if (page.IsContentVisible)
        {
            this._amountExpanded++;
        }
    }
    if (this._amountExpanded > 1)
    {
        e.Cancel = true;
    }
}

I hope it helps.

Best regards,
Alexander
the Telerik team
Tags
PageView
Asked by
DenisCL
Top achievements
Rank 1
Answers by
Alexander
Telerik team
DenisCL
Top achievements
Rank 1
Share this question
or