Too many rows in a gridview?

Discussion in 'ASP .Net' started by cowznofsky, Apr 2, 2008.

  1. cowznofsky

    cowznofsky Guest

    I have a gridview which I load with about 50 rows of high-level data,
    and include a link on each row which will drill down and reload the
    gridview. I have some buttons on the page which provide some other
    functionality, such as exporting the contents of the gridview to excel
    (using my own code).

    This typically works fine, but now I find that if I have a high number
    of rows of the low-level data, say about 5000, then the page does not
    work correctly.

    If I hit the button to send he results to excel, the page_load event
    is not reached, and I get the generic "The page cannot be displayed".
    Hitting a different button raises a popup box with the message
    "response text had 0 length".

    I assume that I've exceeded some maximum for the viewstate.
    cowznofsky, Apr 2, 2008
    #1
    1. Advertising

  2. cowznofsky

    PJ6 Guest

    I believe you can disable the grid's viewstate provided you don't allow
    editing. That's only a quick fix though since you should never display 5K
    rows all at once. Use the grid's built-in paging functionality, unless
    you're using a separate application server to get the data. In that case you
    may want to build paging into the web service or query itself.

    Paul

    "cowznofsky" <> wrote in message
    news:...
    >I have a gridview which I load with about 50 rows of high-level data,
    > and include a link on each row which will drill down and reload the
    > gridview. I have some buttons on the page which provide some other
    > functionality, such as exporting the contents of the gridview to excel
    > (using my own code).
    >
    > This typically works fine, but now I find that if I have a high number
    > of rows of the low-level data, say about 5000, then the page does not
    > work correctly.
    >
    > If I hit the button to send he results to excel, the page_load event
    > is not reached, and I get the generic "The page cannot be displayed".
    > Hitting a different button raises a popup box with the message
    > "response text had 0 length".
    >
    > I assume that I've exceeded some maximum for the viewstate.
    PJ6, Apr 2, 2008
    #2
    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. peelman

    How many threads is too many?

    peelman, Jan 13, 2005, in forum: Java
    Replies:
    12
    Views:
    820
    Esmond Pitt
    Jan 15, 2005
  2. Rhino
    Replies:
    33
    Views:
    1,283
    Oliver Wong
    Dec 22, 2005
  3. rbt
    Replies:
    1
    Views:
    343
  4. How many roles is too many?

    , Jun 13, 2006, in forum: ASP .Net Security
    Replies:
    4
    Views:
    184
    Joe Kaplan \(MVP - ADSI\)
    Jun 18, 2006
  5. Dag Sunde
    Replies:
    4
    Views:
    346
Loading...

Share This Page