473,809 Members | 2,742 Online
Bytes | Software Development & Data Engineering Community
+ Post

Home Posts Topics Members FAQ

Response.Buffer

PJ
When streaming a file attachment to the response stream, should I set

Response.Buffer Output = False

or

Response.Buffer = False

or both?

TIA~PJ
Nov 17 '05 #1
5 8887
Neither are necessary.

--
I hope this helps,
Steve C. Orr, MCSD
http://Steve.Orr.net
"PJ" <pj***@hotmail. com> wrote in message
news:%2******** ********@TK2MSF TNGP12.phx.gbl. ..
When streaming a file attachment to the response stream, should I set

Response.Buffer Output = False

or

Response.Buffer = False

or both?

TIA~PJ

Nov 17 '05 #2
PJ
Do you mean: Neither or necessary if you Flush the stream every time in the
loop?

Also, are one or both of these methods needed...
Response.Close( )
Response.End()

"Steve C. Orr, MCSD" <St***@Orr.ne t> wrote in message
news:%2******** ********@TK2MSF TNGP10.phx.gbl. ..
Neither are necessary.

--
I hope this helps,
Steve C. Orr, MCSD
http://Steve.Orr.net
"PJ" <pj***@hotmail. com> wrote in message
news:%2******** ********@TK2MSF TNGP12.phx.gbl. ..
When streaming a file attachment to the response stream, should I set

Response.Buffer Output = False

or

Response.Buffer = False

or both?

TIA~PJ


Nov 17 '05 #3
If you are streaming a single file through your page, and you haven't output
any HTML in this page, then none of the statements you've mentioned are
necessary for the file download to be successful.

--
I hope this helps,
Steve C. Orr, MCSD
http://Steve.Orr.net
"PJ" <pj***@hotmail. com> wrote in message
news:ev******** ******@tk2msftn gp13.phx.gbl...
Do you mean: Neither or necessary if you Flush the stream every time in the loop?

Also, are one or both of these methods needed...
Response.Close( )
Response.End()

"Steve C. Orr, MCSD" <St***@Orr.ne t> wrote in message
news:%2******** ********@TK2MSF TNGP10.phx.gbl. ..
Neither are necessary.

--
I hope this helps,
Steve C. Orr, MCSD
http://Steve.Orr.net
"PJ" <pj***@hotmail. com> wrote in message
news:%2******** ********@TK2MSF TNGP12.phx.gbl. ..
When streaming a file attachment to the response stream, should I set

Response.Buffer Output = False

or

Response.Buffer = False

or both?

TIA~PJ



Nov 17 '05 #4
PJ
you appear correct w/ the .Buffer and End properties (as long as i set the
Content-Length header), but if i don't call .Flush() in the loop, then
asp.net will buffer the entire response in memory before the open/save
dialog box appears on the client. this is no good for the large file
downloads we have to
"Steve C. Orr, MCSD" <St***@Orr.ne t> wrote in message
news:%2******** ********@TK2MSF TNGP12.phx.gbl. ..
If you are streaming a single file through your page, and you haven't output any HTML in this page, then none of the statements you've mentioned are
necessary for the file download to be successful.

--
I hope this helps,
Steve C. Orr, MCSD
http://Steve.Orr.net
"PJ" <pj***@hotmail. com> wrote in message
news:ev******** ******@tk2msftn gp13.phx.gbl...
Do you mean: Neither or necessary if you Flush the stream every time in

the
loop?

Also, are one or both of these methods needed...
Response.Close( )
Response.End()

"Steve C. Orr, MCSD" <St***@Orr.ne t> wrote in message
news:%2******** ********@TK2MSF TNGP10.phx.gbl. ..
Neither are necessary.

--
I hope this helps,
Steve C. Orr, MCSD
http://Steve.Orr.net
"PJ" <pj***@hotmail. com> wrote in message
news:%2******** ********@TK2MSF TNGP12.phx.gbl. ..
> When streaming a file attachment to the response stream, should I set >
> Response.Buffer Output = False
>
> or
>
> Response.Buffer = False
>
> or both?
>
> TIA~PJ
>
>



Nov 17 '05 #5
Right, the methods exist mostly for performance reasons. They can improve
performance and scalability in certain situations such as the one you've
mentioned. But they are not necessary; they are optimizations.

--
I hope this helps,
Steve C. Orr, MCSD
http://Steve.Orr.net
"PJ" <pj***@hotmail. com> wrote in message
news:OQ******** ******@TK2MSFTN GP10.phx.gbl...
you appear correct w/ the .Buffer and End properties (as long as i set the
Content-Length header), but if i don't call .Flush() in the loop, then
asp.net will buffer the entire response in memory before the open/save
dialog box appears on the client. this is no good for the large file
downloads we have to
"Steve C. Orr, MCSD" <St***@Orr.ne t> wrote in message
news:%2******** ********@TK2MSF TNGP12.phx.gbl. ..
If you are streaming a single file through your page, and you haven't

output
any HTML in this page, then none of the statements you've mentioned are
necessary for the file download to be successful.

--
I hope this helps,
Steve C. Orr, MCSD
http://Steve.Orr.net
"PJ" <pj***@hotmail. com> wrote in message
news:ev******** ******@tk2msftn gp13.phx.gbl...
Do you mean: Neither or necessary if you Flush the stream every time
in
the
loop?

Also, are one or both of these methods needed...
Response.Close( )
Response.End()

"Steve C. Orr, MCSD" <St***@Orr.ne t> wrote in message
news:%2******** ********@TK2MSF TNGP10.phx.gbl. ..
> Neither are necessary.
>
> --
> I hope this helps,
> Steve C. Orr, MCSD
> http://Steve.Orr.net
>
>
> "PJ" <pj***@hotmail. com> wrote in message
> news:%2******** ********@TK2MSF TNGP12.phx.gbl. ..
> > When streaming a file attachment to the response stream, should I

set > >
> > Response.Buffer Output = False
> >
> > or
> >
> > Response.Buffer = False
> >
> > or both?
> >
> > TIA~PJ
> >
> >
>
>



Nov 17 '05 #6

This thread has been closed and replies have been disabled. Please start a new discussion.

Similar topics

0
2600
by: Copa | last post by:
Hello, I am testing buffering an asp page and Flushing information out to the browser, hence i wrote the code in an asp page that follows this Message Post. The loops are suppose to simulate long search processes with a flush after each search. When i Navigate to the page, redirect to it from another page, or type the URL to this page in the browser, the page is buffered until it reaches the end of the file and is then displayed all at...
3
17328
by: Brian Piotrowski | last post by:
Hi All, I'm trying to run a simple query from an ASP page. I want the query to select each individual field in a table and compare it to another table. If the value doesn't exist, I want it reported. Here's the code I have to do this check: 'Check to see if there are any assemblies not in the database! strSQL = "select substring(mtoc,2,6) as deadmodel from bos_data where substring(bos_data.mtoc,2,6) not in (select code from...
7
6376
by: Stephanie | last post by:
If response.buffer is set to true, and no response.flush has been executed, is it accurate to expect that my browser should not be rendering the content which I (well Ok, someone else) is sending in response.write statements? Thanks.
0
1863
by: abraham | last post by:
Hi In an .aspx codebehind file I retrieve a file from a database and write it to the response buffer, so the browser pops up a 'save file' dialog and the user can save the file to disk. The relevant part of the code (VB) that does this is listed below: Response.Buffer = True Response.Clear()
2
1843
by: Deepak Kashyap | last post by:
I have placed Response.Buffer = True in the page load event. But when the page gets displayed on the browser, it does not buffer completely and then display, it works as Response.Buffer = False. Is there anything which I'm missing... Deepak
5
9133
by: Joe | last post by:
Could someone please explain the practical differences between Response.Buffer and Response.BufferOutput? TIA, -- Joe VB.NET/C#/ASP.NET/ASP/VB/C++/Web and DB development/VBA Automation
2
1654
by: Steven Bazeley | last post by:
I had a download failure problem with a 95MB wmv file. I thought it was my code but I could not find anything wrong. So I tested the download by replacing the 95MB file with a smaller one (20MB). It worked fine. When I contacted my hosting company this is what they told me.
12
7925
by: Jim Rodgers | last post by:
I have a big asp file that has an error under certain conditions -- totally repeatable. However, it only fails when I set response.buffer = True at the top. WHen I set it False in order to debug it, it works every time! I even set it to True, but did a .Flush just before the error, and the error won't happen. It only happens when response.buffer is True and no .response.flush is issued. The error is a string variable turns-up empty...
1
6340
by: Gurpal | last post by:
I'm getting this error when I test this page. Here is the error: Response object error 'ASP 0251 : 80004005' Response Buffer Limit Exceeded /test/test4.asp, line 0 Execution of the ASP page caused the Response Buffer to exceed its configured limit.
0
9721
marktang
by: marktang | last post by:
ONU (Optical Network Unit) is one of the key components for providing high-speed Internet services. Its primary function is to act as an endpoint device located at the user's premises. However, people are often confused as to whether an ONU can Work As a Router. In this blog post, we’ll explore What is ONU, What Is Router, ONU & Router’s main usage, and What is the difference between ONU and Router. Let’s take a closer look ! Part I. Meaning of...
1
10379
by: Hystou | last post by:
Overview: Windows 11 and 10 have less user interface control over operating system update behaviour than previous versions of Windows. In Windows 11 and 10, there is no way to turn off the Windows Update option using the Control Panel or Settings app; it automatically checks for updates and installs any it finds, whether you like it or not. For most users, this new feature is actually very convenient. If you want to control the update process,...
0
10115
tracyyun
by: tracyyun | last post by:
Dear forum friends, With the development of smart home technology, a variety of wireless communication protocols have appeared on the market, such as Zigbee, Z-Wave, Wi-Fi, Bluetooth, etc. Each protocol has its own unique characteristics and advantages, but as a user who is planning to build a smart home system, I am a bit confused by the choice of these technologies. I'm particularly interested in Zigbee because I've heard it does some...
0
9199
agi2029
by: agi2029 | last post by:
Let's talk about the concept of autonomous AI software engineers and no-code agents. These AIs are designed to manage the entire lifecycle of a software development project—planning, coding, testing, and deployment—without human intervention. Imagine an AI that can take a project description, break it down, write the code, debug it, and then launch it, all on its own.... Now, this would greatly impact the work of software developers. The idea...
1
7660
isladogs
by: isladogs | last post by:
The next Access Europe User Group meeting will be on Wednesday 1 May 2024 starting at 18:00 UK time (6PM UTC+1) and finishing by 19:30 (7.30PM). In this session, we are pleased to welcome a new presenter, Adolph Dupré who will be discussing some powerful techniques for using class modules. He will explain when you may want to use classes instead of User Defined Types (UDT). For example, to manage the data in unbound forms. Adolph will...
0
6881
by: conductexam | last post by:
I have .net C# application in which I am extracting data from word file and save it in database particularly. To store word all data as it is I am converting the whole word file firstly in HTML and then checking html paragraph one by one. At the time of converting from word file to html my equations which are in the word document file was convert into image. Globals.ThisAddIn.Application.ActiveDocument.Select();...
0
5550
by: TSSRALBI | last post by:
Hello I'm a network technician in training and I need your help. I am currently learning how to create and manage the different types of VPNs and I have a question about LAN-to-LAN VPNs. The last exercise I practiced was to create a LAN-to-LAN VPN between two Pfsense firewalls, by using IPSEC protocols. I succeeded, with both firewalls in the same network. But I'm wondering if it's possible to do the same thing, with 2 Pfsense firewalls...
0
5687
by: adsilva | last post by:
A Windows Forms form does not have the event Unload, like VB6. What one acts like?
2
3861
muto222
by: muto222 | last post by:
How can i add a mobile payment intergratation into php mysql website.

By using Bytes.com and it's services, you agree to our Privacy Policy and Terms of Use.

To disable or enable advertisements and analytics tracking please visit the manage ads & tracking page.