473,473 Members | 1,974 Online
Bytes | Software Development & Data Engineering Community
Create Post

Home Posts Topics Members FAQ

Multiple Requests (windows)

PJ
My web application will open a popup that, upon a user action, will initiate
a request that will result in a file being sent as an attachment to the
client. The download works fine, except that the user is no longer able to
browse and get responses in the main window. The request just seems to hang
and does not get the response until the download is finished. It only seems
to effect the session in which the download is taking place. Other clients,
even on the same computer, are not experiencing request/response issues. I
doubt it's an issue with the server side code I am using for the download,
but here it is nonetheless. Any advice on this issue would be greatly
appreciated. TIA~ PJ

Dim br As New BinaryReader(fs)
Dim offset As Long
Response.Clear()
Response.BufferOutput = False
Response.Buffer = False
Response.ContentType = "application/octet-stream"
Response.AddHeader("Content-Disposition", "attachment; filename=" +
fileName)
Response.AddHeader("Content-Length", fs.Length.ToString())
Response.Flush()

Dim totalSize As Long = fs.Length
Dim size As Long
Do
If offset + CHUNK_SIZE > totalSize Then
size = totalSize - offset
Else
size = CHUNK_SIZE
End If
If Not Response.IsClientConnected Then
Exit Do
End If
Response.BinaryWrite(br.ReadBytes(Convert.ToInt32( size)))
fs.Flush()
Response.Flush()
offset += size
Loop Until offset >= totalSize
fs.Close()
br.Close()
Response.Close()
Nov 17 '05 #1
0 959

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

Similar topics

11
by: Ohaya | last post by:
Hi, I'm trying to understand a situation where ASP seems to be "blocking" of "queuing" requests. This is on a Win2K Advanced Server, with IIS5. I've seen some posts (e.g.,...
9
by: Abhishek Srivastava | last post by:
Hello All, In IIS 6.0 We have a concept of worker processes and application pools. As I understand it, we can have multiple worker process per appliction pool. Each worker process is dedicated...
7
by: jsale | last post by:
I have made an ASP.NET web application that connects to SQL Server, reading and writing data using classes. I was recommended to use session objects to store the data per user, because each user...
10
by: John | last post by:
I currently have a Windows Service that runs Transactions that are very Processor/Memory Intensive. I have a requirement to deploy multiple instances of the Web service on the Same server. Each...
4
by: sracherla | last post by:
I am trying to write a simple windows service that accepts an incoming request; receives a string input and sends a string output. I need this connection to stay alive until the client closes it....
35
by: keerthyragavendran | last post by:
hi i'm downloading a single file using multiple threads... how can i specify a particular range of bytes alone from a single large file... for example say if i need only bytes ranging from...
1
by: pintoo | last post by:
Hi, I have 2 sites (Site A, B) running on same windows 2003 server pointing to different home directories. User logs into site A and is shown a.aspx page and user credentials are saved in...
0
by: Jordan S. | last post by:
I'm just wondering if it's possible to have multiple HttpHandlerFactory classes active at once in an ASP.NET 3.5 app. In particular, I want for the "built-in" HttpHandlerFactory that ships with...
0
by: Hystou | last post by:
Most computers default to English, but sometimes we require a different language, especially when relocating. Forgot to request a specific language before your computer shipped? No problem! You can...
0
Oralloy
by: Oralloy | last post by:
Hello folks, I am unable to find appropriate documentation on the type promotion of bit-fields when using the generalised comparison operator "<=>". The problem is that using the GNU compilers,...
1
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...
0
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...
1
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...
0
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...
0
by: adsilva | last post by:
A Windows Forms form does not have the event Unload, like VB6. What one acts like?
1
muto222
php
by: muto222 | last post by:
How can i add a mobile payment intergratation into php mysql website.
0
bsmnconsultancy
by: bsmnconsultancy | last post by:
In today's digital era, a well-designed website is crucial for businesses looking to succeed. Whether you're a small business owner or a large corporation in Toronto, having a strong online presence...

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.