Velocity Reviews

Velocity Reviews (http://www.velocityreviews.com/forums/index.php)
-   ASP .Net (http://www.velocityreviews.com/forums/f29-asp-net.html)
-   -   PlatformNotSupportedException when accessing HttpReponse.Headers (http://www.velocityreviews.com/forums/t603590-platformnotsupportedexception-when-accessing-httpreponse-headers.html)

newsgroup.poster@gmail.com 04-02-2008 04:02 PM

PlatformNotSupportedException when accessing HttpReponse.Headers
 
I encounter the following exception when accessing
HttpResponse.Headers after having installed .net 3.5 SDK:

[PlatformNotSupportedException: This operation requires IIS integrated
pipeline mode.]
System.Web.HttpResponse.get_Headers() +3300614

My server is windows 2003 (iis6), my dev environment is winxppro
(either iis5 or vswebdevserver).

I've saw description of this exception here

http://msdn2.microsoft.com/en-us/lib...ceptionsToggle

but I don't understand why it should apply because I don't use iis 7.

I'm working arround by hacking ContentType property appending required
headers, but I wonder if there is a way to fix this problem?

Thanks,

Gauthier Segay

Mark Fitzpatrick 04-02-2008 04:09 PM

Re: PlatformNotSupportedException when accessing HttpReponse.Headers
 
The feature you're looking for only works with IIS 7, that's why you're
getting the PlatformNotSupportedException. If you try to run this code on
IIS 6 you'll get this exact error because it's not available. The way you're
doing this is correct for the version of IIS you have available.

Hope this helps,
Mark Fitzpatrick
Microsoft MVP - Expression

<newsgroup.poster@gmail.com> wrote in message
news:938d7785-61af-491e-b8d0-5a18aaaca18b@e6g2000prf.googlegroups.com...
>I encounter the following exception when accessing
> HttpResponse.Headers after having installed .net 3.5 SDK:
>
> [PlatformNotSupportedException: This operation requires IIS integrated
> pipeline mode.]
> System.Web.HttpResponse.get_Headers() +3300614
>
> My server is windows 2003 (iis6), my dev environment is winxppro
> (either iis5 or vswebdevserver).
>
> I've saw description of this exception here
>
> http://msdn2.microsoft.com/en-us/lib...ceptionsToggle
>
> but I don't understand why it should apply because I don't use iis 7.
>
> I'm working arround by hacking ContentType property appending required
> headers, but I wonder if there is a way to fix this problem?
>
> Thanks,
>
> Gauthier Segay



newsgroup.poster@gmail.com 04-02-2008 04:19 PM

Re: PlatformNotSupportedException when accessing HttpReponse.Headers
 
I got confused because I sure have used headers with asp.net before,
but it seems I was wrong and always relied on this trick.

Thanks for your answer and clarification.

On 2 avr, 18:09, "Mark Fitzpatrick" <markf...@fitzme.com> wrote:
> The feature you're looking for only works with IIS 7, that's why you're
> getting the PlatformNotSupportedException. If you try to run this code on
> IIS 6 you'll get this exact error because it's not available. The way you're
> doing this is correct for the version of IIS you have available.
>
> Hope this helps,
> Mark Fitzpatrick
> Microsoft MVP - Expression
>
> <newsgroup.pos...@gmail.com> wrote in message
>
> news:938d7785-61af-491e-b8d0-5a18aaaca18b@e6g2000prf.googlegroups.com...
>
>
>
> >I encounter the following exception when accessing
> > HttpResponse.Headers after having installed .net 3.5 SDK:

>
> > [PlatformNotSupportedException: This operation requires IIS integrated
> > pipeline mode.]
> > * System.Web.HttpResponse.get_Headers() +3300614

>
> > My server is windows 2003 (iis6), my dev environment is winxppro
> > (either iis5 or vswebdevserver).

>
> > I've saw description of this exception here

>
> >http://msdn2.microsoft.com/en-us/lib...presponse.head...

>
> > but I don't understand why it should apply because I don't use iis 7.

>
> > I'm working arround by hacking ContentType property appending required
> > headers, but I wonder if there is a way to fix this problem?

>
> > Thanks,

>
> > Gauthier Segay- Masquer le texte des messages précédents -

>
> - Afficher le texte des messages précédents -




All times are GMT. The time now is 04:33 PM.

Powered by vBulletin®. Copyright ©2000 - 2014, vBulletin Solutions, Inc.
SEO by vBSEO ©2010, Crawlability, Inc.