Too much data in DataGrid when page refreshes

Discussion in 'ASP .Net Datagrid Control' started by Shannon Cayze, Jul 1, 2003.

  1. Hello all,

    I'm new to web development and ASP.Net and I'm sure this is a pretty
    fundamental question. I've performed a query that returns about 70,000
    records and have put this data in a DataGrid. Now, if the user does
    something requiring a refresh of the page, I get a page cannot be
    displayed message because it was unavailable. However, if I perform a
    query that only returns 10,000 records, the refresh works fine. Is
    there any way that on the client I can clear the DataGrid before it is
    posted to the server? Also, are there any better ways of handling this
    scenario?

    Thanks in advance,
    Shannon
     
    Shannon Cayze, Jul 1, 2003
    #1
    1. Advertising

  2. Turn ViewState off for the Grid. That is the recommended way to handle this
    issue.

    --
    Naveen K Kohli
    http://www.netomatix.com
    "Shannon Cayze" <> wrote in message
    news:...
    > Hello all,
    >
    > I'm new to web development and ASP.Net and I'm sure this is a pretty
    > fundamental question. I've performed a query that returns about 70,000
    > records and have put this data in a DataGrid. Now, if the user does
    > something requiring a refresh of the page, I get a page cannot be
    > displayed message because it was unavailable. However, if I perform a
    > query that only returns 10,000 records, the refresh works fine. Is
    > there any way that on the client I can clear the DataGrid before it is
    > posted to the server? Also, are there any better ways of handling this
    > scenario?
    >
    > Thanks in advance,
    > Shannon
     
    Naveen K Kohli, Jul 1, 2003
    #2
    1. Advertising

  3. Shannon Cayze

    Saravana Guest

    It is not recommended to fetch all the records together, instead you can go
    for paging. For more details about paging in datagrid, refer my article
    http://www.microsoft.com/india/msdn/articles/PaginginDataGridWebServerContro
    l.aspx

    If you are not going for paging and If your grid is going to be only
    readonly, then you can disable viewstate for your datagrid.

    HTH
    Saravana
    Microsoft India Community Star,
    MCAD,SE,SD,DBA.


    "Shannon Cayze" <> wrote in message
    news:...
    > Hello all,
    >
    > I'm new to web development and ASP.Net and I'm sure this is a pretty
    > fundamental question. I've performed a query that returns about 70,000
    > records and have put this data in a DataGrid. Now, if the user does
    > something requiring a refresh of the page, I get a page cannot be
    > displayed message because it was unavailable. However, if I perform a
    > query that only returns 10,000 records, the refresh works fine. Is
    > there any way that on the client I can clear the DataGrid before it is
    > posted to the server? Also, are there any better ways of handling this
    > scenario?
    >
    > Thanks in advance,
    > Shannon
     
    Saravana, Jul 2, 2003
    #3
    1. Advertising

Want to reply to this thread or ask your own question?

It takes just 2 minutes to sign up (and it's free!). Just click the sign up button to choose a username and then you can ask your own questions on the forum.
Similar Threads
  1. SB
    Replies:
    0
    Views:
    378
  2. AAJ
    Replies:
    2
    Views:
    333
  3. DanWeaver
    Replies:
    3
    Views:
    370
    DanWeaver
    Feb 11, 2007
  4. cpp4ever
    Replies:
    3
    Views:
    382
    Francesco
    Sep 8, 2009
  5. Replies:
    0
    Views:
    111
Loading...

Share This Page