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

后端 未结 19 2796
生来不讨喜
生来不讨喜 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条回答
  •  旧时难觅i
    2020-12-07 23:05

    I'm having the same problem, and came across this blog, which basically states that Linq-To-Sql has got a problem in it's optimistic concurrency where:

    1. High precision datetime fields are used. The solution is to set UpdateCheck to never for that column your DBML file
    2. GridView columns which are set to invisible are accessing a property on the data object (this second reason makes no sense, but it seems to be all the rage on that blog).

    I haven't tried these solutions yet, but will post back here once I have.

提交回复
热议问题