Go Back   Velocity Reviews > Newsgroups > ASP Net
User Name
Password
Register FAQ Members List Calendar Search Today's Posts Mark Forums Read

Reply

ASP Net - datagrid too slow

 
Thread Tools Search this Thread
Old 08-02-2004, 09:26 PM   #1
Default datagrid too slow


In my application I have a datagrid. The code calls a Stored procedure and
brings like 200 records. I created a dataset and then a dataview to bind the
results of the query to my grid using MyGrid.DataBind() Once the
records are loaded, to handle the next, previous button is too slow. I have
in the same screen OptionsBox and everytime I click in any option I show
some text fields in the screen. Anything the user does is very slow. When my
query returns less than 100 records everything is fast but when I load more
records in the datagrid is slow. If this is in memory why is it so slow? In
real time application I will bring more than 1000 registers and this can';t
be so slow.

This definitions I'm doing only once in the code
Dim myds As New DataSet

Dim mydv As New DataView

What can I do to improve and make it fast? I've work with VB 6.0 and once
the info. is loaded in the grid it was so fast not like the machine is
thinking a lot



Thanks in advance

Jennyfer




Jennyfer J Barco
  Reply With Quote
Old 08-02-2004, 09:47 PM   #2
Raterus
 
Posts: n/a
Default Re: datagrid too slow
It doesn't sound like the bottleneck here is asp.net, but your stored procedure. I'd ensure you are doing good coding practices there, and also make sure you have optimized how the data is being stored in sql server. (primary keys set, indexes?) You could write books on that kind of optimization though.

"Jennyfer J Barco" <> wrote in message news:...
> In my application I have a datagrid. The code calls a Stored procedure and
> brings like 200 records. I created a dataset and then a dataview to bind the
> results of the query to my grid using MyGrid.DataBind() Once the
> records are loaded, to handle the next, previous button is too slow. I have
> in the same screen OptionsBox and everytime I click in any option I show
> some text fields in the screen. Anything the user does is very slow. When my
> query returns less than 100 records everything is fast but when I load more
> records in the datagrid is slow. If this is in memory why is it so slow? In
> real time application I will bring more than 1000 registers and this can';t
> be so slow.
>
> This definitions I'm doing only once in the code
> Dim myds As New DataSet
>
> Dim mydv As New DataView
>
> What can I do to improve and make it fast? I've work with VB 6.0 and once
> the info. is loaded in the grid it was so fast not like the machine is
> thinking a lot
>
>
>
> Thanks in advance
>
> Jennyfer
>
>



Raterus
  Reply With Quote
Old 08-03-2004, 05:27 PM   #3
Jennyfer J Barco
 
Posts: n/a
Default Re: datagrid too slow
The first time it loads the page, it calls the sp and is bringing the info.
very fast. The grid appears so fast. The thing is that if there are many
records in the grid working with the controls is very slow. Making a
Options_SelectedIndexChanged which is an option radiobuttonlist is very
slow. When I bring to the datagrid a few records executing this
Options_SelectedIndexChanged is very fast. I traced the program and I know
calling the SP and doing the databind is not slow even if he is returning me
thousands of records. It's when I load many records in the grid the problem.
In the Page_Load I call the SP only when is not Ispostback which means the
first time because I know .NET runs the page_load everytime you do anything
like moving to the next page or select an option in the radiobuttom.

Thanks

"Raterus" <> wrote in message
news:...
It doesn't sound like the bottleneck here is asp.net, but your stored
procedure. I'd ensure you are doing good coding practices there, and also
make sure you have optimized how the data is being stored in sql server.
(primary keys set, indexes?) You could write books on that kind of
optimization though.

"Jennyfer J Barco" <> wrote in message
news:...
> In my application I have a datagrid. The code calls a Stored procedure and
> brings like 200 records. I created a dataset and then a dataview to bind

the
> results of the query to my grid using MyGrid.DataBind() Once the
> records are loaded, to handle the next, previous button is too slow. I

have
> in the same screen OptionsBox and everytime I click in any option I show
> some text fields in the screen. Anything the user does is very slow. When

my
> query returns less than 100 records everything is fast but when I load

more
> records in the datagrid is slow. If this is in memory why is it so slow?

In
> real time application I will bring more than 1000 registers and this

can';t
> be so slow.
>
> This definitions I'm doing only once in the code
> Dim myds As New DataSet
>
> Dim mydv As New DataView
>
> What can I do to improve and make it fast? I've work with VB 6.0 and once
> the info. is loaded in the grid it was so fast not like the machine is
> thinking a lot
>
>
>
> Thanks in advance
>
> Jennyfer
>
>





Jennyfer J Barco
  Reply With Quote
Old 08-06-2004, 04:34 PM   #4
Jennyfer J Barco
 
Posts: n/a
Default Re: datagrid too slow
Do you have any idea of this? The problem is not the sp that brings the
data, it's very fast. The problem is when I load hundreds of records. Isn't
this design to work with a lot of information?

Thanks and help please

Jennyfer

"Jennyfer J Barco" <> wrote in message
news:%...
> The first time it loads the page, it calls the sp and is bringing the

info.
> very fast. The grid appears so fast. The thing is that if there are many
> records in the grid working with the controls is very slow. Making a
> Options_SelectedIndexChanged which is an option radiobuttonlist is very
> slow. When I bring to the datagrid a few records executing this
> Options_SelectedIndexChanged is very fast. I traced the program and I know
> calling the SP and doing the databind is not slow even if he is returning

me
> thousands of records. It's when I load many records in the grid the

problem.
> In the Page_Load I call the SP only when is not Ispostback which means the
> first time because I know .NET runs the page_load everytime you do

anything
> like moving to the next page or select an option in the radiobuttom.
>
> Thanks
>
> "Raterus" <> wrote in message
> news:...
> It doesn't sound like the bottleneck here is asp.net, but your stored
> procedure. I'd ensure you are doing good coding practices there, and also
> make sure you have optimized how the data is being stored in sql server.
> (primary keys set, indexes?) You could write books on that kind of
> optimization though.
>
> "Jennyfer J Barco" <> wrote in message
> news:...
> > In my application I have a datagrid. The code calls a Stored procedure

and
> > brings like 200 records. I created a dataset and then a dataview to bind

> the
> > results of the query to my grid using MyGrid.DataBind() Once the
> > records are loaded, to handle the next, previous button is too slow. I

> have
> > in the same screen OptionsBox and everytime I click in any option I show
> > some text fields in the screen. Anything the user does is very slow.

When
> my
> > query returns less than 100 records everything is fast but when I load

> more
> > records in the datagrid is slow. If this is in memory why is it so slow?

> In
> > real time application I will bring more than 1000 registers and this

> can';t
> > be so slow.
> >
> > This definitions I'm doing only once in the code
> > Dim myds As New DataSet
> >
> > Dim mydv As New DataView
> >
> > What can I do to improve and make it fast? I've work with VB 6.0 and

once
> > the info. is loaded in the grid it was so fast not like the machine is
> > thinking a lot
> >
> >
> >
> > Thanks in advance
> >
> > Jennyfer
> >
> >

>
>





Jennyfer J Barco
  Reply With Quote
Reply


Thread Tools Search this Thread
Search this Thread:

Advanced Search

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

vB code is On
Smilies are On
[IMG] code is On
HTML code is Off
Trackbacks are Off
Pingbacks are Off
Refbacks are Off

Similar Threads
Thread Thread Starter Forum Replies Last Post
Get datagrid textbox value kanchangorak Software 0 03-11-2009 11:11 AM
Loading 24,000 rows into C# .net Datagrid Kagu Software 0 03-10-2009 06:51 PM
Custom built computer running slow ExecByte General Help Related Topics 0 11-24-2008 12:12 AM
ASP.NET VB Using ItemDataBound to create textbox in datagrid rows. smi59550 General Help Related Topics 0 01-18-2008 07:42 PM
Disable ASP Button in a Datagrid ChrisClayko General Help Related Topics 0 08-02-2006 03:08 AM




SEO by vBSEO 3.3.2 ©2009, Crawlability, Inc.

1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 22 23 24 25 26 27 28 29 30 31 32 33 34 35 36 37 38 39 40 41 42 43 44 45 46