472,353 Members | 1,054 Online
Bytes | Software Development & Data Engineering Community
+ Post

Home Posts Topics Members FAQ

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

Correct coding in IE Download window form


There is a possibility to show DownloadFile form in web browser using following peace of code
Code: ( text )

HttpContext context = HttpContext.Current;
context.Response.ContentType = "application/octet-stream";
context.Response.AddHeader("Content-Disposition","attachment; filename=\"" + fileName + "\"");

but there is somenthing missing because when I use filename with "#" it's displayed in wrong way as "_" in IE 7.0 (in firefox is OK). You have a choice in this window to save and to open the file. When you want to save -> filename will be wrong, when you choose to open filename in eg. word filename shown at the top of the window of word will be ok.

So I used ascii code of # then it save correct filename but when I choose to open it in word it filename has ascii codes.

I assume that I should give correct coding type somewhere in this peace of code ... but I don't know where. Can you help me ?
Aug 23 '07 #1
0 980

Sign in to post your reply or Sign up for a free account.

Similar topics

by: Programatix | last post by:
Hi, I'm working on a project which includes XML WebServices and Windows Form application. The Windows Form application will call the XML...
by: ajaykrishna | last post by:
Hi I'm using ASP.NET for my application. In one of the place, I am downloading data to excel document. But, here the File Download window is...
by: gb | last post by:
hi, i placed System.Windows.Forms.WebBrowser in my WinForm. When i tried loading word document, it opens the File Download window. My question...
by: Kueishiong Tu | last post by:
I have a .net window form application but I have to get data from various web sites. How do I make Http request (preferrably via post method) from...
by: david | last post by:
I have written the Web Services in VBaic .Net. One function interface: DataSet GetAllPatients() which will be called in remote client and return...
by: martin1 | last post by:
All, is there window form refresh property? I try to set up window form refresh per minute. Thanks
by: Melisa | last post by:
Hi, How can i create bitmap of a window form with all its child controls without showing this form? 1. I am trying to create bitmap image of a...
by: Darqer | last post by:
Hello There is a possibility to show DownloadFile form in web browser using following peace of code HttpContext context = HttpContext.Current;...
by: =?Utf-8?B?bWFydGluMQ==?= | last post by:
All, I present some data on the window form, then I try to save window form as file on the local C drive, like save word file, can anyone know...
by: Kemmylinns12 | last post by:
Blockchain technology has emerged as a transformative force in the business world, offering unprecedented opportunities for innovation and...
by: Naresh1 | last post by:
What is WebLogic Admin Training? WebLogic Admin Training is a specialized program designed to equip individuals with the skills and knowledge...
by: antdb | last post by:
Ⅰ. Advantage of AntDB: hyper-convergence + streaming processing engine In the overall architecture, a new "hyper-convergence" concept was...
by: Matthew3360 | last post by:
Hi, I have a python app that i want to be able to get variables from a php page on my webserver. My python app is on my computer. How would I make it...
by: AndyPSV | last post by:
HOW CAN I CREATE AN AI with an .executable file that would suck all files in the folder and on my computerHOW CAN I CREATE AN AI with an .executable...
by: Arjunsri | last post by:
I have a Redshift database that I need to use as an import data source. I have configured the DSN connection using the server, port, database, and...
by: WisdomUfot | last post by:
It's an interesting question you've got about how Gmail hides the HTTP referrer when a link in an email is clicked. While I don't have the specific...
by: BLUEPANDA | last post by:
At BluePanda Dev, we're passionate about building high-quality software and sharing our knowledge with the community. That's why we've created a SaaS...
by: Rahul1995seven | last post by:
Introduction: In the realm of programming languages, Python has emerged as a powerhouse. With its simplicity, versatility, and robustness, Python...

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.