System.Data.Linq.ChangeConflictException: Row not found or changed

后端 未结 19 2753
生来不讨喜
生来不讨喜 2020-12-07 22:21

I am trying to delete a selected gridview row using LINQ (No LINQDataSource).

When the selection is changed, the detailsview binding is changed also. I can add a new

19条回答
  •  野趣味
    野趣味 (楼主)
    2020-12-07 23:14

    You are getting this error quite possibly because one of your fields has something different in the Linq To SQL designer and in the actual database.

    In my case, it was because one of the fields was nullable in the database and not nullable in the designer, making it nullable in the designer as well solved the problem immediately.

提交回复
热议问题