I have the following code to download file from the website (pdf, word etc.,).
I have problem when open the document file. It does not open properly in microsoft word. i.e it shows the symbol webpage in the word. Hope it opens as webpage not document in Microsoft word. I found this when i directly open the doucment there is no webpage symbol appears in the word and the document open properly but when i click the download button it opens as webpage in word. How to solve this problem?
if fs.FileExists(server.MapPath(snfile))=true then
Response.AddHeader "Content-Disposition","attachment; filename="&fname
set objStream =server.CreateObject("ADODB.Stream")
Response.Write "File not found!"