Saturday, March 10, 2012

User Controls (ascxs) and AJAX - take 2

Partial postbacks can slow down depending on how much you're updating. Large gridviews or dropdowns with a lot of items can slow down partial postbacks a lot. With that many controls on the form, I would almost say that a full postback is probably best. Make sure you're ScriptManager has PartialPageLoading=true (or something like that) and your UpdatePanel has UpdateMode="Conditional" and keep your updatepanels isolated to only the parts of your web page that need it.

Don't just wrap it around user controls and if only a few textboxes are updated. Use Triggers to update the panels to keep all of the panels from updating. If you've already done all of that, then throw out AJAX and try not displaying so much on one page at once :) (God help the business user).


Thank you! This is exactly what I need to know.

I'll check out the PartialPageLoading and UpdateMode attributes. I'm not familiar with them, so I'll do some reading. I'll also verify that the UpdatePanel is as isolated as possible to the controls that are being updated.

Thanks again.


I isolated the UpdatePanel to the few textboxes that were being updated, and it's lightening quick now. Wonderful!

No comments:

Post a Comment