473,395 Members | 2,713 Online
Bytes | Software Development & Data Engineering Community
Post Job

Home Posts Topics Members FAQ

Join Bytes to post your question to a community of 473,395 software developers and data experts.

Starting Download Problem with IIS 6


I am attempting to make a small popup window push a downloaded file.
What works fine with the Visual Studio 2005 web server does not appear
to work with IIS6.

My main page code looks like this:

LiteralControl litMove = new LiteralControl();
litMove.Text = @"
<script language='JavaScript'>
<!--
var dlWindow = window.open('theFile', 'fileDl',
'toolbar=1,location=0,directories=0,status=0,menub ar=0,scrollbars=0,resizable=0,width=10,left=10,hei ght=24');
//-->
</script>
";
litMove.Text = litMove.Text.Replace( "theFile" , theFile );
this.pageBody.Controls.Add( litMove );

The actual download code (in a new page appearing as "theFile" in the
previous code page above) looks like this:

Response.Clear();
Response.AddHeader( "Content-Disposition" , "attachment;filename=" +
HttpUtility.UrlPathEncode(myFile) );
Response.AddHeader( "Content-Length" , new FileInfo( fullFilePath
).Length.ToString() );
Response.ContentType = "application/octet-stream";
Response.TransmitFile( fullFilePath );
Response.End();

What happens is that on IIS6, the popup appears for 1/2-second and
disappears. On the Visual Studio Cassini server, the window appears
and then the user is prompted for save.

Users are IE7 clients.

Thanks.

Jan 16 '07 #1
0 912

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

Similar topics

40
by: Geoff Cox | last post by:
Hello, The following code works with document.getElementById('picture').src = window.src; but not if I increase the index to 1, ie document.getElementById('picture').src = window.src;
2
by: belial | last post by:
Hi! I am new on the group and join in as i am in bad need of help in C programming.I'm a fresher and got to tackle the basics of C in the next few months,so i wonder if anyone on that group could...
2
by: Tassos | last post by:
Hi, I know that I need some public token keys or something like that to allow my application to run over internet on a local host. Is there any tutorial how to do that? (In german language I will...
3
by: fred bliss | last post by:
Hi All We have a new server running the latest framework, windows server 2003 & IIS 6.0, and we're getting the following error when we try to load the app in IE. Server Error in...
12
by: Prabu Subroto | last post by:
Dear my friends... I am using postgres 7.4 and SuSE 9.1. I want to use auto_increment as on MySQL. I look up the documentation on www.postgres.com and I found "serial" . But I don't know...
4
by: anne001 | last post by:
Hi For a class, students are going to run an experiment on line. Each time a subject runs, his/her data is appended to one giant text file. Their own data set will be just one line starting with...
1
by: David Van D | last post by:
Hi there, A few weeks until I begin my journey towards a degree in Computer Science at Canterbury University in New Zealand, Anyway the course tutors are going to be teaching us JAVA wth bluej...
2
by: agisoec | last post by:
Hi, All, I'm a bit new to this forum, and not too sharp at designing pages, so please bear with me. I posted a question in another forum and it was suggested that it might be better here. I...
1
by: laredotornado | last post by:
Hi, I just installed the most recent version of ruby and rails on my Fedora Core 5 Linux system. For some reason, my server isn't starting, but I noticed one line upon startup: =Rails...
0
by: ryjfgjl | last post by:
In our work, we often receive Excel tables with data in the same format. If we want to analyze these data, it can be difficult to analyze them because the data is spread across multiple Excel files...
0
by: emmanuelkatto | last post by:
Hi All, I am Emmanuel katto from Uganda. I want to ask what challenges you've faced while migrating a website to cloud. Please let me know. Thanks! Emmanuel
0
BarryA
by: BarryA | last post by:
What are the essential steps and strategies outlined in the Data Structures and Algorithms (DSA) roadmap for aspiring data scientists? How can individuals effectively utilize this roadmap to progress...
1
by: Sonnysonu | last post by:
This is the data of csv file 1 2 3 1 2 3 1 2 3 1 2 3 2 3 2 3 3 the lengths should be different i have to store the data by column-wise with in the specific length. suppose the i have to...
0
by: Hystou | last post by:
There are some requirements for setting up RAID: 1. The motherboard and BIOS support RAID configuration. 2. The motherboard has 2 or more available SATA protocol SSD/HDD slots (including MSATA, M.2...
0
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,...
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,...
0
jinu1996
by: jinu1996 | last post by:
In today's digital age, having a compelling online presence is paramount for businesses aiming to thrive in a competitive landscape. At the heart of this digital strategy lies an intricately woven...
0
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...

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.