Author: olaamigos | Posted on: 1/28/2009 1:22:29 PM | Views : 265

Hello,

If I have a space between the filename, how do I reserve the filename without changing it?  The situation I have right now is that somehow it replaces the empty space between the filename with the underscore.  For example: the original filename is "Report 2008.pdf" with a space b/w Report and 2008, when file download, it shows the filename with underscore ("Report_2008").  Why is it and how do I reserve the filename for downloading?


Here is the code for downloading:

filepath: c:\Reports\Report 2008.pdf

file.Name = Report 2008.pdf

But the output for filename is "Report_2008.pdf", why is it and how do I fix this?  See code below:

 

Response.Clear();
Response.AddHeader("Content-Disposition" ...

Go to the complete details ...