Is there an overhead to a listview if its unused

3 posts, 1 answers
  1. Paul
    Paul avatar
    55 posts
    Member since:
    Nov 2010

    Posted 09 Sep 2011 Link to this post

    Hi. I have a website where there a some different types of data (A, B, C...). The obvious solution is for me to have a separate page to display each type of data (Page_A, Page_B....). Each would have a listview to display a list of the corresponding data and each listview would be different to reflect the different types of data and also the different functionality required for each type/list. HOWEVER, there is some complex functionality separate to the actual listviews that would be common to all of the pages. This functionality is, in part, used to produce the actual datasource required for the listview.

    So I have a choice. Multiple pages that have different lists displayed on each page but which replicate common functionality.

    Or I create a single page that has the common functionality which also generates the datasource and that single page could have multiple listviews but then attach/bind the datasource to just one of the listviews. That would mean that there are some other listviews on the page that end up being unused. Would this cause an overhead?

    Any views or comments would be really appreciated. The main functionality and code associated with the page(s) is the common code.
  2. Answer
    Tsvetina
    Admin
    Tsvetina avatar
    1876 posts

    Posted 15 Sep 2011 Link to this post

    Hello Paul,

    As long as you set Visible="false" to the unneeded listviews, they will not slow down performance on your page since in such scenarios they do not fire NeedDataSource and the consequtive Item events and do not render anything on the page.

    Regards,
    Tsvetina
    the Telerik team
    Browse the vast support resources we have to jump start your development with RadControls for ASP.NET AJAX. See how to integrate our AJAX controls seamlessly in SharePoint 2007/2010 visiting our common SharePoint portal
  3. UI for ASP.NET Ajax is Ready for VS 2017
  4. Paul
    Paul avatar
    55 posts
    Member since:
    Nov 2010

    Posted 15 Sep 2011 Link to this post

    That is what I had assumed but I just wanted to check. Many thanks
Back to Top