Response.BinaryWrite Help

Discussion in 'ASP .Net' started by Dave, Oct 27, 2008.

  1. Dave

    Dave Guest

    Why when posting a txt file as Binary does the HTML for the web page
    also post with it? Or is it the Response.BinaryWrite that's doing
    it? Any help would be appreciated.

    Thanks
     
    Dave, Oct 27, 2008
    #1
    1. Advertising

  2. "Dave" <> wrote in message
    news:...
    > Why when posting a txt file as Binary does the HTML for the web page
    > also post with it? Or is it the Response.BinaryWrite that's doing
    > it? Any help would be appreciated.
    >


    Why wouldn't the HTML post with it?

    <html>
    <body>
    <%Response.BinaryWrite(some array of bytes here)%>
    </body>
    </html>

    what would you expect to happen?

    I suspect you have this code in the Page_Load event and haven't done a
    Response.End() before leaving the event.

    You might be better off using an .ashx for this task.

    --
    Anthony Jones - MVP ASP/ASP.NET
     
    Anthony Jones, Oct 27, 2008
    #2
    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. DAC
    Replies:
    1
    Views:
    1,856
    Steve C. Orr, MCSD
    Jul 31, 2003
  2. =?Utf-8?B?QnJhZCBSb2JlcnRz?=

    RE: Response.BinaryWrite or something causes multiple posts

    =?Utf-8?B?QnJhZCBSb2JlcnRz?=, Aug 19, 2004, in forum: ASP .Net
    Replies:
    1
    Views:
    560
    =?Utf-8?B?RGFuIEM=?=
    Aug 19, 2004
  3. bruce barker
    Replies:
    2
    Views:
    638
    bruce barker
    Aug 19, 2004
  4. Replies:
    1
    Views:
    837
  5. Dave

    Response.BinaryWrite HELP!

    Dave, Oct 27, 2008, in forum: ASP .Net
    Replies:
    1
    Views:
    314
    Göran Andersson
    Oct 27, 2008
Loading...

Share This Page