PHPFixing
  • Privacy Policy
  • TOS
  • Ask Question
  • Contact Us
  • Home
  • PHP
  • Programming
  • SQL Injection
  • Web3.0

Wednesday, May 18, 2022

[FIXED] How to incrementally load an asp.net page having a Repeater control?

 May 18, 2022     asp.net, controls, partial, rendering, repeater     No comments   

Issue

I have a page that shows results of a query. The results are displayed using a Repeater control that emits a div element that holds text data and images related to that particular result. The problem is that the page takes considerable amount of time to load partly because of the huge amount of processing required to generate the data.

So, is there a way to improve the page load by incrementally rendering the page rather than the have the user wait until the full data is available

I was thinking about sending the text data of each result first, and then as the images are available, send them to client to be displayed with each result. I guess I will need to use AJAX, but I'm not exactly sure how to get this done.

Does anyone have any suggestions or experience with this situation?

Thanks,


Solution

If you are going to control the flow, you can set up flushing on the binding event so the data is flushed out prior to having everything. But that may not be the best option; and, with standard tagged documents (rather than CSS docs) it might not help anyway, as the browser may not render even when flushed (depends on the tags in the Repeater).

Another option is retrieving via AJAX and flusing as data comes in (or at least showing a "wait for it" graphic). The wait graphic can be done without AJAX, but the load with AJAX pattern is well documented.

You can also limit the amount of data on a single page, unless this is a report of some type.



Answered By - Gregory A Beamer
Answer Checked By - David Goodson (PHPFixing Volunteer)
  • Share This:  
  •  Facebook
  •  Twitter
  •  Stumble
  •  Digg
Newer Post Older Post Home

0 Comments:

Post a Comment

Note: Only a member of this blog may post a comment.

Total Pageviews

Featured Post

Why Learn PHP Programming

Why Learn PHP Programming A widely-used open source scripting language PHP is one of the most popular programming languages in the world. It...

Subscribe To

Posts
Atom
Posts
Comments
Atom
Comments

Copyright © PHPFixing