0

The context cannot be used while the model is being created. This exception may be thrown if the context is used inside the OnModelCreating method or if the same context instance is accessed by multiple threads concurrently. Note that instance members of DbContext and related classes are not guaranteed to be thread safe.

The old programmer make connection using .edmx file and now I use the make connection using EFPowerTools so how can I manage the code..

Mosh Feu
  • 28,354
  • 16
  • 88
  • 135
Ashok
  • 11
  • 1
  • 1
  • 1
    Can you paste your code here, the code that throws the exception? – Alberto Monteiro Dec 31 '15 at 10:53
  • 1
    Possible duplicate of ["Context cannot be used while the model is being created" exception with ASP.NET Identity](http://stackoverflow.com/questions/21344232/context-cannot-be-used-while-the-model-is-being-created-exception-with-asp-net) – Alberto Monteiro Dec 31 '15 at 10:54

0 Answers0