Ulhas Tuscano
Ulhas Tuscano

Reputation: 5620

How to improve page loading delays?

I am using gridview control of .net framework 4.0. My list contains 1000 of rows which i am binding to a gridview on each postback. Hence, My page is taking time to load I want to speed up the system. Is there any other control available which can enhance the performance or is there any other way to achieve this? What all i want is faster performance

Upvotes: 0

Views: 482

Answers (3)

Xavier Poinas
Xavier Poinas

Reputation: 19743

You might be able to use faster controls, such as the Repeater, but it depends on what feature you really need. Are you only displaying the data or is it editable?

With such a large amount of data you can look at optimizing what HTML you use for rendering, as you may be able to split the page size by half...

Upvotes: 1

EKS
EKS

Reputation: 5623

First step should be to do a preformance check to find out what exacly is slow. Check where in the code things take time, it could be one of many things.
1) If the control uses javascript, perhaps the users are on a old version of their browser with a slow javascript engine.
2) Perhaps the issue is bandwidth?
3) Perhaps its missing SQL index
and on it goes.

Dont guess at what is wrong, find out for sure what is taking the time, and solve then one at the time.

Like Forgotten Semicolon suggested loading via Ajax might be solution, it would give the user a better idea what is going on.

Other then that i would would heavly suggest caching if posible, you can use the built in Cache options to cache the datatable.

Upvotes: 1

anurodhp
anurodhp

Reputation: 356

In addition to the point about not binding on every postback, I am assuming the datasource is an SQL database. You should probably check to see how fast the query runs. Make sure you have properly indexed your tables.

Upvotes: 0

Related Questions