+ Start a Discussion
MWelch_WTMWelch_WT 

HUGE VF table grinding page to virtual halt.

I've got a VF datatable displaying about 35-40 rows, iterating over a list of a wrapper class, which contains a custom object.  The resulting table has about 450-550 inputtext fields and 450-550 hidden input fields.  I know it sounds like a user interface nightmare, but for this application, it actually works pretty well.

 

The problem is that, once we do get up to the 35 or 40 rows, the performance is terrible.  Adding another row takes 5-10 seconds.  Same with deleting a row.  I've got some AJAX-y stuff happening onchange on each inputtext field, as well, and that's brutally slow, too.

 

I think I've got the controller pretty tight, as, if I comment out all the inputtext and hidden fields, and just let the vf and controller iterate over the table, performance is pretty good.

 

Are there any techniques I can employ, on the VF or Apex side, that'll increase the performance?  I've tried messing with actionRegion, but that doesn't seem to have any effect.

 

Worse case is I have to rewrite to present much less editable content at once, but that really will get in the way of the end-users' workflow.

 

Thanks for any input. 

TehNrdTehNrd

When you say adding another row are you doing something that requires you to dynamically rerender the entire table to display one additional row? If so, I'm not sure how improve peformance here. As bad as this may sound I have found that sometimes reloading the entire page can acutally be faster than rerendering a large dataTable.

 

One area I have tried to improver perfomance in large dataTables is to only rerender the contents of a column rather then the entire table. 

 

I think alot of this has to do with the performance of the browser.

 

 

Message Edited by TehNrd on 06-16-2009 01:20 PM
infoweldernickinfoweldernick

I'm not sure what your use case is, but one thing to consider would be to break out the interface into separate pages, such as a wizard type interface, as I think you suggested.  The other would be to consider using a technology like Adobe Flex since Flash is then rendering all of those elements instead of the browser itself.  Plus, you'll get a better looking interface.

 

Good luck.