S
sunil
Hi all,
I have a web application in which I have to open a "chm" file that
exists on the local file system. I am able to open other files such as
PDF, DOC files by writing the Response's output stream.
But I do not exactly know the Response.ContentType for chm files.
I have used the following code to handle the case for chm files
System.IO.StreamReader sr = new System.IO.StreamReader(this.Path);
FileInfo file = new FileInfo(this.Path);
Response.Clear();
Response.ContentType = "application/vnd.ms-htmlhelp";
Response.WriteFile(file.FullName);
sr.Close();
But this is not opening the document.
Any help?
I have a web application in which I have to open a "chm" file that
exists on the local file system. I am able to open other files such as
PDF, DOC files by writing the Response's output stream.
But I do not exactly know the Response.ContentType for chm files.
I have used the following code to handle the case for chm files
System.IO.StreamReader sr = new System.IO.StreamReader(this.Path);
FileInfo file = new FileInfo(this.Path);
Response.Clear();
Response.ContentType = "application/vnd.ms-htmlhelp";
Response.WriteFile(file.FullName);
sr.Close();
But this is not opening the document.
Any help?