Quantcast
Channel: ASPNETWebStack Issue Tracker Rss Feed
Viewing all articles
Browse latest Browse all 7215

Closed Issue: Server cannot append header after HTTP headers have been sent. [556]

$
0
0
Hi All,

I have recently started using Web API (version 4.0.20710.0) and have created an ActionFilterAttribute that sets some caching headers in the OnActionExecuted method.

I also have a IHttpModule that sets some headers in the PostRequestHandlerExecute event using request.AppendHeader when this happens I get the following error

Exception: System.Web.HttpException
Message: Server cannot append header after HTTP headers have been sent.
Source: System.Web
at System.Web.HttpResponse.AppendHeader(String name, String value)

This does not seem to be the case in MVC 3 (haven't tested this in MVC 4). Not sure if I am missing something but looking at the ASP.NET pipeline this should not be the case http://msdn.microsoft.com/en-us/library/ms178473(v=vs.100).aspx

Any help would be greatly appreciated.
Comments: Verified.

Viewing all articles
Browse latest Browse all 7215

Trending Articles



<script src="https://jsc.adskeeper.com/r/s/rssing.com.1596347.js" async> </script>