views:

32

answers:

2

In IE, when user uses Export To Excel (downloading .xls file) functionality in my SSL website, following error message is popping up:-

Internet Explorer cannot download file from server........

This is the exact definition of the issue here:-

CAUSE: In order for Internet Explorer to open documents in Office (or any out-of-process, ActiveX document server), Internet Explorer must save the file to the local cache directory and ask the associated application to load the file by using IPersistFile::Load. If the file is not stored to disk, this operation fails. When Internet Explorer communicates with a secure Web site through SSL, Internet Explorer enforces any no-cache request. If the header or headers are present, Internet Explorer does not cache the file. Consequently, Office cannot open the file. RESOLUTION: Web sites that want to allow this type of operation should remove the no-cache header or headers.

I cannot remove no-cache header from whole website(SSL). Can anybody suggest some work around here? Export to Excel functionality is only on one page of entire website.

+1  A: 

Try calling Response.Headers.Clear() before the server code the writes out the excel file does anything else.

Joel Coehoorn
Response.Clear(); This is I am already doing. is it same as Response.Headers.Clear()?
Novice
Nope. Did not work...
Novice
A: 

Unfortunately, I could not find any work around so far. Only solution, i found is to remove no-cache header from my SSL website.

Novice