GridView/AccessDataSource update

Discussion in 'ASP .Net' started by msnews.microsoft.com, Jul 19, 2005.

  1. I've got a paging and sorting enabled GridView whose datasource is and
    AccessDataSource. I build the SelectCommand at PageLoad - it's a union
    query to show items and comments of the user logged in. This all works
    fine.

    I tried to set AccessDataSource.UpdateCommand in the code behind (C#) by
    handling the GridView.OnUpdating event - since this is supposed to fire
    before the record is updated, I thought I could set the UpdateCommand here.
    Didn't work.

    So I tried setting the UpdateCommand in design, adding it as an element in
    the .aspx, with asp:ControlParameters inside UpdateParameters. This didn't
    work either.

    Both ways that didn't work didn't kick me back to Visual Studio in debug
    mode - instead I get (I think the same msg for both approaches) the message
    below. How do I go about troubleshooting this?


    Invalid postback or callback argument.
    Description: An unhandled exception occurred during the execution of the
    current web request. Please review the stack trace for more information
    about the error and where it originated in the code.

    Exception Details: System.ArgumentException: Invalid postback or callback
    argument.
    [ArgumentException: Invalid postback or callback argument.]
    System.Web.UI.ClientScriptManager.ValidateEvent(String uniqueId, String
    argument) +2089124
    System.Web.UI.WebControls.ImageButton.RaisePostBackEvent(String
    eventArgument) +101
    System.Web.UI.WebControls.ImageButton.System.Web.UI.IPostBackEventHandler.RaisePostBackEvent(String
    eventArgument) +7
    System.Web.UI.Page.RaisePostBackEvent(IPostBackEventHandler
    sourceControl, String eventArgument) +11
    System.Web.UI.Page.RaisePostBackEvent(NameValueCollection postData) +33
    System.Web.UI.Page.ProcessRequestMain(Boolean
    includeStagesBeforeAsyncPoint, Boolean includeStagesAfterAsyncPoint) +5191
     
    msnews.microsoft.com, Jul 19, 2005
    #1
    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. DC
    Replies:
    0
    Views:
    381
  2. Miro
    Replies:
    0
    Views:
    878
  3. Jesse Houwing
    Replies:
    0
    Views:
    490
    Jesse Houwing
    May 11, 2009
  4. Miro
    Replies:
    1
    Views:
    1,416
  5. Morris Neuman

    Gridview update not working for AccessDataSource

    Morris Neuman, Oct 7, 2008, in forum: ASP .Net Web Controls
    Replies:
    6
    Views:
    384
    Morris Neuman
    Oct 13, 2008
Loading...

Share This Page