We have a MVC 4 project and using Structure Map as an IoC framework. When we make an async call to the service class that using DbContext it throws an exception:
Value cannot be null.
Parameter name: httpContext
Exception Details: System.ArgumentNullException: Value cannot be null.
Parameter name: httpContext
Once it has thrown this:
The operation cannot be completed because the DbContext has been disposed.
How can I correct this?
DbContext
into the container? – Humid