1

I have to make a ASP.NET MVC web page wherein a word doc has to be viewed. The idea is that the page allows user to view documents stored in a local directory.

I tried to google it, but all I could find useful is that word doc converted to .htm format can be viewed inside an iframe, but I have to make use of the .doc file.

I need to apply the same technique to view ppt and visio diagrams.

Can anyone suggest any ideas.

Thanks.

8
  • You only specify .doc so I am assuming you aren't dealing with .docx or pptx files?
    – ahsteele
    Apr 26, 2011 at 5:14
  • well, you can always iframe the document itself however client browser rules will determine if they're displayed inline or downloaded. If you want to force them to view it inline you'll have to convert the document to a form native to the browser, such as html, flash viewer or images. Apr 26, 2011 at 5:14
  • @ahsteele : yes I am limiting myself to doc and ppt files only
    – Jake
    Apr 26, 2011 at 5:16
  • @BuildStarted : the page needs to open in chrome and firefox
    – Jake
    Apr 26, 2011 at 5:19
  • Correct, which means the client will either need a plugin to view the doc/ppt files or you have to convert them into a generic format such as those listed. Google Docs Viewer is probably the easiest path for you docs.google.com/viewer you can embed their stuff use the embedded=true to embed it in your webpage Apr 26, 2011 at 5:23

0

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service and acknowledge you have read our privacy policy.

Browse other questions tagged or ask your own question.