Community

Disposing of the DbContext Object

(Peter Vogel) I have two separate styles for using the DbContext object. In one style I create the DbContext object when my class is instantiated, either as part of defining a field for my class: