Results 1 to 6 of 6

Thread: ASP.net Datagrid SelectedIndexChanged

  1. #1
    Join Date
    Mar 2006
    Posts
    35
    Rep Power
    0

    Default ASP.net Datagrid SelectedIndexChanged

    Hi,

    I'm having problems getting the ASP.net datagrid to update a page on a row click, or datagrid selecteIndexChanged Event.

    Can Anyone Give me any suggetions on which direction to head in?

    Thanks

  2. #2
    Join Date
    Feb 2005
    Posts
    85
    Rep Power
    0

    Default

    make sure that the auto postback property for the grid is set to true
    Code King aka Code WizZzard: Motivated By The Challenge, Driven By The Will To Succeed.

    In The Land Of Programmers, The Code WizZzard Is KING. Sen on anything VB

  3. #3
    Join Date
    Mar 2006
    Posts
    35
    Rep Power
    0

    Default

    Are you sure this is a feature of an asp.net 2003 data grid

  4. #4
    Join Date
    Feb 2005
    Posts
    85
    Rep Power
    0

    Default

    Sorry about that I was thinking about a dropdownlist.

    Send a sample code to illustrate what you are trying to do.
    Code King aka Code WizZzard: Motivated By The Challenge, Driven By The Will To Succeed.

    In The Land Of Programmers, The Code WizZzard Is KING. Sen on anything VB

  5. #5
    Join Date
    Sep 2004
    Posts
    681
    Rep Power
    0

    Default

    Quote Originally Posted by ToxXxic View Post
    Send a sample code to illustrate what you are trying to do.
    Yeah, the event handler code would probably give some idea of what is going on. Handling events fired from within a DataGrid (or any other webcontrol for that matter) can be tricky if you haven't done it before. It isn't as straight forward as dealing with events fired at the Page level.

  6. #6
    Join Date
    Dec 2002
    Posts
    500
    Rep Power
    0

    Default

    make sure you have a link button with command name = select, or a command column that has select....

    you see i once thought that just clicking that row would cause the selected index changed event like in windows forms... but no, you have to put in place what causes the selection... and may a times it is a button with CommandName : "Select".
    Cultured in Aggression and Koding like a Warrior!!
    “Common sense is instinct. Enough of it is genius.” - George Bernard Shaw.
    "The significant problems we face cannot be solved by the same level of thinking that created them." - Albert Einstein

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •