Visual Basic > Visual Basic Forums > Visual Basic General > Is there a way to embed a Microsoft Word document to a Windows form?
Ask a questionAsk a question
 

AnswerIs there a way to embed a Microsoft Word document to a Windows form?

  • Thursday, March 13, 2008 6:57 PMDavid Reynolds in Cincinnati Users MedalsUsers MedalsUsers MedalsUsers MedalsUsers Medals
     

     

    Hi there.  I was wondering about how you would embed a Microsoft Word document in a Windows form.  I was using RichTextBox to load it in RTF, but I don't like the way the RichTextBox loads some of Word's Tables.  Additionally, I like the selection tool better in Word than the RichTextbox on Word Tables as well.

Answers

  • Wednesday, March 19, 2008 11:05 AMMartin Xie - MSFTMSFT, ModeratorUsers MedalsUsers MedalsUsers MedalsUsers MedalsUsers Medals
     Answer

     David Reynolds in Cincinnati wrote:

    I was wondering about how you would embed a Microsoft Word document in a Windows form.

     

    Hi David,

     

    Here are two approaches to opening word document inside a Winfodws form.

     

    1. Using WebBrowser control to open (but without menubar and toolbar).

    WebBrowser1.Navigate("C:\myDocment.doc")

    2. Using third-part component winwordcontrol to open (with menubar and toolbar).

    http://www.codeproject.com/KB/office/WordInDotnet.aspx

    This article including demo project and C# source code, explains how you can integrate Microsoft Word (including Menubar and Toolbar) in your .NET applications.

     

    By the way, here are two helpful tools:

    1) Instant VB: C# to VB converter

    The tool can convert entire C# project to corresponding VB.NET project, also can convert code snippet.

    2) Convert C# code to VB.NET code by means of this Code Translator tool.

     

     

    Also try this approach to open word document inside a Panel control.

    http://forums.microsoft.com/MSDN/ShowPost.aspx?PostID=2616199&SiteID=1

     

     

    Regards,

    Martin

All Replies

  • Wednesday, March 19, 2008 11:05 AMMartin Xie - MSFTMSFT, ModeratorUsers MedalsUsers MedalsUsers MedalsUsers MedalsUsers Medals
     Answer

     David Reynolds in Cincinnati wrote:

    I was wondering about how you would embed a Microsoft Word document in a Windows form.

     

    Hi David,

     

    Here are two approaches to opening word document inside a Winfodws form.

     

    1. Using WebBrowser control to open (but without menubar and toolbar).

    WebBrowser1.Navigate("C:\myDocment.doc")

    2. Using third-part component winwordcontrol to open (with menubar and toolbar).

    http://www.codeproject.com/KB/office/WordInDotnet.aspx

    This article including demo project and C# source code, explains how you can integrate Microsoft Word (including Menubar and Toolbar) in your .NET applications.

     

    By the way, here are two helpful tools:

    1) Instant VB: C# to VB converter

    The tool can convert entire C# project to corresponding VB.NET project, also can convert code snippet.

    2) Convert C# code to VB.NET code by means of this Code Translator tool.

     

     

    Also try this approach to open word document inside a Panel control.

    http://forums.microsoft.com/MSDN/ShowPost.aspx?PostID=2616199&SiteID=1

     

     

    Regards,

    Martin