onItemCommand

Discussion in 'ASP .Net' started by Jim Heavey, Feb 26, 2004.

  1. Jim Heavey

    Jim Heavey Guest

    Hello, I have a situation which is occuring and I am not quites sure how to
    overcome the problem.

    I have a web page which displays a datagrid, The user can click on a items
    within the row(s) presented in the grid. When The user clicks, The logic
    in the routine idenfied in the "OnItemCommand" is executed. This logic
    runs a new a new query which populates the datatable and then databinds the
    datagird.

    What I am finding that the "OnItemCommand" is running onces for the click
    event, and then running again after the results of the query are posted to
    the Data Table and the datagrid is bound to that data table. The second
    time it fails becuase the row which was present on the first click is no
    longer found in the newly recreated datatable.

    How to I get around this?
     
    Jim Heavey, Feb 26, 2004
    #1
    1. Advertisements

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. Rick White
    Replies:
    1
    Views:
    1,739
    Natty Gur
    Jan 13, 2004
  2. DaWoE

    Datalist onItemCommand not firing

    DaWoE, Jun 25, 2004, in forum: ASP .Net
    Replies:
    1
    Views:
    2,788
    DaWoE
    Jun 25, 2004
  3. Mukund Patel

    repeater OnItemCommand event

    Mukund Patel, Jan 10, 2005, in forum: ASP .Net
    Replies:
    1
    Views:
    2,879
    Eliyahu Goldin
    Jan 10, 2005
  4. =?Utf-8?B?QXNoYQ==?=
    Replies:
    0
    Views:
    535
    =?Utf-8?B?QXNoYQ==?=
    Jan 20, 2005
  5. bdwgarth
    Replies:
    1
    Views:
    1,142
    =?Utf-8?B?dmluYXk=?=
    Jun 22, 2005
  6. =?Utf-8?B?QW50b25pbyBDYXJwZW50aWVyaQ==?=

    Problem with OnItemCommand event and Loadtemplate

    =?Utf-8?B?QW50b25pbyBDYXJwZW50aWVyaQ==?=, Sep 26, 2005, in forum: ASP .Net
    Replies:
    5
    Views:
    1,080
    leakingimplants
    Apr 16, 2008
  7. LeAnne
    Replies:
    0
    Views:
    1,262
    LeAnne
    May 14, 2006
  8. Steve Hershoff
    Replies:
    0
    Views:
    546
    Steve Hershoff
    Aug 9, 2006
Loading...