Server Error in '/' Application.

Invalid use of response filter

Description: An unhandled exception occurred during the execution of the current web request. Please review the stack trace for more information about the error and where it originated in the code.

Exception Details: System.Web.HttpException: Invalid use of response filter

Source Error:

An unhandled exception was generated during the execution of the current web request. Information regarding the origin and location of the exception can be identified using the exception stack trace below.

Stack Trace:


[HttpException (0x80004005): Invalid use of response filter]
   System.Web.HttpResponseStreamFilterSink.VerifyState() +4490452
   System.Web.HttpResponseStreamFilterSink.Write(Byte[] buffer, Int32 offset, Int32 count) +28
   System.Web.HttpWriter.FilterIntegrated(Boolean finalFiltering, IIS7WorkerRequest wr) +338
   System.Web.HttpResponse.FilterOutput() +118
   System.Web.CallFilterExecutionStep.System.Web.HttpApplication.IExecutionStep.Execute() +62
   System.Web.HttpApplication.ExecuteStep(IExecutionStep step, Boolean& completedSynchronously) +92


Version Information: Microsoft .NET Framework Version:4.0.30319; ASP.NET Version:4.6.1055.0