Populating RadPageView NavigationBar from class

1 Answer 32 Views
PageView
RUNSystem
Top achievements
Rank 1
Iron
Iron
RUNSystem asked on 04 Jun 2024, 03:11 PM

Hi Telerik,

 

I'm using C# and and RadPageView NavigationBar component for my WinForms application.

I think I'll give a background story first.

I implement a RadPageView with NavigationBar, and also implement a search bar between the hamburger menu and the RadPageView items

The item's is populated from a class

 

The "search menu" is used to filter the displayed menu 



And when I clear the search menu's filter, the RadPageViewItems is re-loaded with the previous class data. But, it takes a long time due to a lot of records (FYI, i have ~1000 menus that equivalent to ~1000 RadPageViewItems)



Is it possible to improve the load speed? Like, maybe, any mechanism that stores the fully loaded menu as a local-storage in RadPageView's function/module that I should call when the search menu is cleared after it has been filled?

Thanks in advance!

1 Answer, 1 is accepted

Sort by
0
Dinko | Tech Support Engineer
Telerik team
answered on 07 Jun 2024, 09:17 AM

Hello RUNSystem,

I appreciate the provided details.

Having ~1000 pages in the control will take some time to repopulate the control. I am assuming that when the user is typing in the custom search area, items are removed or added to the Pages collection. The control does not provide a mechanism to store the pages to improve the performance in this specific scenario. What comes to my mind is to hide the items instead of adding and removing the items. 

Here is what I have in mind:

foreach (RadPageViewPage page in this.radNavigationView1.Pages)
{
    //search criteria
    if (page.Item.Visibility == ElementVisibility.Visible)
    {
        page.Item.Visibility = ElementVisibility.Collapsed;
    }
    else
    {
        page.Item.Visibility = ElementVisibility.Visible;
    }              
}

The control contains a large number of pages, but still, I hope that this will improve the performance in your application.

Regards,
Dinko | Tech Support Engineer
Progress Telerik

Love the Telerik and Kendo UI products and believe more people should try them? Invite a fellow developer to become a Progress customer and each of you can get a $50 Amazon gift voucher.

RUNSystem
Top achievements
Rank 1
Iron
Iron
commented on 07 Jun 2024, 09:20 AM

Hi Dinko,

Thank you for the response.

I would love to try the solution and update the result ASAP!

Tags
PageView
Asked by
RUNSystem
Top achievements
Rank 1
Iron
Iron
Answers by
Dinko | Tech Support Engineer
Telerik team
Share this question
or