I'm wondering what's the best option to display a pdf/doc document inside form in my c# winforms app.
This control should only allow do display preview. Edtiting documents should be forbidden.
I'm looking for free solution.
The best option would be to attach a few separate *.dlls to solution but it's not a requirement.
I wrote something that can do this for Word Documents by taking advantage of the WebBrowser control for WinForms. Hopefully it might do you some good:
http://codinglight.blogspot.com/2008/10/simple-docbrowser-control.html
Consider using the preview handlers for Vista, Windows 7. I used the code provided by Brad Smith (with corrections from the comments).
http://www.brad-smith.info/blog/archives/79 - Hosting Preview Handlers in Windows Forms Applications
If you love us? You can donate to us via Paypal or buy me a coffee so we can maintain and grow! Thank you!
Donate Us With