PlatformNotSupportedException when accessing HttpReponse.Headers

Discussion in 'ASP .Net' started by newsgroup.poster@gmail.com, Apr 2, 2008.

  1. Guest

    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/library/system.web.httpresponse.headers.aspx#ddueExceptionsToggle

    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
     
    , Apr 2, 2008
    #1
    1. Advertising

  2. 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

    <> wrote in message
    news:...
    >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/library/system.web.httpresponse.headers.aspx#ddueExceptionsToggle
    >
    > 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, Apr 2, 2008
    #2
    1. Advertising

  3. Guest

    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" <> 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
    >
    > <> wrote in message
    >
    > news:...
    >
    >
    >
    > >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/library/system.web.httpresponse.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 -
     
    , Apr 2, 2008
    #3
    1. Advertising

Want to reply to this thread or ask your own question?

It takes just 2 minutes to sign up (and it's free!). Just click the sign up button to choose a username and then you can ask your own questions on the forum.
Similar Threads
  1. Douglas Gage

    Datagrid Headers???

    Douglas Gage, Jan 15, 2004, in forum: ASP .Net
    Replies:
    0
    Views:
    503
    Douglas Gage
    Jan 15, 2004
  2. nomadx
    Replies:
    1
    Views:
    501
    dinser
    Sep 19, 2003
  3. dont bother
    Replies:
    0
    Views:
    868
    dont bother
    Mar 3, 2004
  4. Phil
    Replies:
    4
    Views:
    734
    Gabriel Genellina
    Jan 17, 2010
  5. Ian
    Replies:
    2
    Views:
    2,112
Loading...

Share This Page