Gridview DataKeys property not set when PageIndexChanged fires

Discussion in 'ASP .Net' started by =?Utf-8?B?UmljayBEcm9za2U=?=, Dec 13, 2006.

  1. In the PageIndexChanged event of an ASP.Net 2.0 GridView the Rows property
    has rows but the DataKeys property has 0 Items ?

    This definitely seems like a bug to me. Has anyone come up with a good
    workaround ?

    --
    Rick Droske
    =?Utf-8?B?UmljayBEcm9za2U=?=, Dec 13, 2006
    #1
    1. Advertising

  2. DataBinding the GridView again at the top of PageIndexChanged fixes it but
    obviously not ideal. Hopefully its not actually causing another trip to the
    SQL server....


    --
    Rick Droske


    "Rick Droske" wrote:

    > In the PageIndexChanged event of an ASP.Net 2.0 GridView the Rows property
    > has rows but the DataKeys property has 0 Items ?
    >
    > This definitely seems like a bug to me. Has anyone come up with a good
    > workaround ?
    >
    > --
    > Rick Droske
    =?Utf-8?B?UmljayBEcm9za2U=?=, Dec 13, 2006
    #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. Alex
    Replies:
    0
    Views:
    366
  2. =?Utf-8?B?TGluZ28=?=

    Gridview asp.net 2.0 datakeys not loading

    =?Utf-8?B?TGluZ28=?=, Oct 31, 2005, in forum: ASP .Net
    Replies:
    0
    Views:
    591
    =?Utf-8?B?TGluZ28=?=
    Oct 31, 2005
  3. Benton
    Replies:
    0
    Views:
    707
    Benton
    Dec 19, 2006
  4. sevilsivle

    GridView.DataKeys appear not to be filled

    sevilsivle, May 2, 2006, in forum: ASP .Net Web Controls
    Replies:
    0
    Views:
    130
    sevilsivle
    May 2, 2006
  5. Replies:
    3
    Views:
    981
Loading...

Share This Page