Word Automation: Write RTF text without going through clipboard Word Automation: Write RTF text without going through clipboard vba vba

Word Automation: Write RTF text without going through clipboard


Put the RTF in a file instead of the clipboard, then insert from the file, e.g.

Selection.InsertFile FileName:="myfile.rtf", Range :="", _ ConfirmConversions:=False, Link:=False, Attachment:=False


You can use a RichTextbox to convert RTF to text or vice versa.

RichTextBox r = new RichTextBox();r.Rtf = strRTFString;Console.WriteLine(r.Text);