Your Privacy Matters: We use our own and third-party cookies to improve your experience on our website. By continuing to use the website we understand that you accept their use. Cookie Policy
140
Requested record cannot be found by key.
posted

When i try to update the values of the row in 2nd or 3rd or etc., page in WebDataGrid. I got the error

"Requested record cannot be found by key ". I'm binding the grid at runtime in pageload.

 TIA

  • 760
    posted

    <ig:EditingCore AutoCRUD="False">  in aspx

    Provide below lines in code behind

    set the datasource in page_load()

    {

    grd.DataSource = <obj>;

    if(!IsPostBack)

    {

    }

    }

     

    In grd_RowUpdating and grd_RowDeleing event after deleing or updating the row.

    grd.ClearDataSource();

    grd.DataBind();