Display Word document on a Windows form

Is there a way to display a word document on a windows form and make it uneditable?

I am using Visual Studio 2008
LVL 35
YZlatAsked:
Who is Participating?
I wear a lot of hats...

"The solutions and answers provided on Experts Exchange have been extremely helpful to me over the last few years. I wear a lot of hats - Developer, Database Administrator, Help Desk, etc., so I know a lot of things but not a lot about one thing. Experts Exchange gives me answers from people who do know a lot about one thing, in a easy to use platform." -Todd S.

YZlatAuthor Commented:
it's an old link and the link on that forum is broken
0
Jacques Bourgeois (James Burger)PresidentCommented:
Not directly, there is now way that I know to load a .doc or .docx in .NET.

There used to be an OLEControl in VB6 that could do that, but even there, it was not always working well. It seems that they never were able to do one in .NET. COM (on which Word is based), is too different from .NET.

However, you could write code to save the document as .rtf and reload the generated .rtf into a RichTextBox control. You need to have a copy of Word installed on the computer however to do so.

Expect to lose a few things in the formatting however, specially if you work with .docx files, because .rtf cannot display everything that a Word document can at a high level. As an exempla, things such as diagonals in table cells do not translate to .rtf files.
0

Experts Exchange Solution brought to you by

Your issues matter to us.

Facing a tech roadblock? Get the help and guidance you need from experienced professionals who care. Ask your question anytime, anywhere, with no hassle.

Start your 7-day free trial
YZlatAuthor Commented:
I've decided to take a different route but your suggestion was the best answer I got
0
It's more than this solution.Get answers and train to solve all your tech problems - anytime, anywhere.Try it for free Edge Out The Competitionfor your dream job with proven skills and certifications.Get started today Stand Outas the employee with proven skills.Start learning today for free Move Your Career Forwardwith certification training in the latest technologies.Start your trial today
C#

From novice to tech pro — start learning today.

Question has a verified solution.

Are you are experiencing a similar issue? Get a personalized answer when you ask a related question.

Have a better answer? Share it in a comment.