SharpDevelop Community

Get your problems solved!
Welcome to SharpDevelop Community Sign in | Join | Help
in Search

copy text from ICSharpCode.TextEditor.TexEditorControl to Word 2007

Last post 08-04-2008 2:01 PM by DanielGrunwald. 2 replies.
Page 1 of 1 (3 items)
Sort Posts: Previous Next
  • 08-03-2008 7:42 AM

    • lszk
    • Not Ranked
    • Joined on 08-03-2008
    • Posts 2

    copy text from ICSharpCode.TextEditor.TexEditorControl to Word 2007

     I'm writing a Word Add-In to hightlight the source code.
    I have colored the text in ICSharpCode.TextEditor.TexEditorControl and now I want to copy it to MS Word with these colors. If I do that by ctrl+c/ctrl+v all works fine. But how can I do it in c#?

  • 08-04-2008 3:27 AM In reply to

    • lszk
    • Not Ranked
    • Joined on 08-03-2008
    • Posts 2

    Re: copy text from ICSharpCode.TextEditor.TexEditorControl to Word 2007

     I found somewhere that I have to save it in rtf file. In source code to this library I found a RtfWriter class. Like a paramether method to generate rtf needs TextArea object. But I have my TextEditorControl only. How to convert it?

  • 08-04-2008 2:01 PM In reply to

    Re: copy text from ICSharpCode.TextEditor.TexEditorControl to Word 2007

    Use "textEditorControl.ActiveTextAreaControl.TextArea".

    Daniel Grunwald
Page 1 of 1 (3 items)
Powered by Community Server (Commercial Edition), by Telligent Systems
Don't contact us via this (fleischfalle@alphasierrapapa.com) email address.