I have an Entity Data Model that I have created, and its pulling in records from a SQLite DB. One of the Tables is People, I want to override the person.Equals() method but I'm unsure where to go to make such a change since the Person object is auto-generated and I don't even see where that autogen code resides. I know how to override Equals on a hand made object, its just where to do that on an autogen one.
相关问题
- Sorting 3 numbers without branching [closed]
- Graphics.DrawImage() - Throws out of memory except
- Why am I getting UnauthorizedAccessException on th
- 求获取指定qq 资料的方法
- How to know full paths to DLL's from .csproj f
You need to create a partial class. Add a new .cs file to your solution, and start it like this:
You can try using partial classes - I think you can find autogenerated code in the solution. If you find out that Equals is not overriden by default and generated class is partial (I think it should be partial) than you can add another file to your solution and place partial class with implenentation of Equals there: