![]() |
|
#1
|
||||
|
||||
![]()
What you need is
Code:
Sub rtf_test() Dim oDoc As Document Dim strPath As String Set oDoc = ActiveDocument oDoc.Save If Not ActiveDocument.path = "" Then strPath = ActiveDocument.FullName strPath = Left(strPath, InStrRev(strPath, Chr(46))) & ".rtf" oDoc.SaveAs2 FileName:=strPath, FileFormat:=wdFormatRTF Else oDoc.SaveAs2 FileName:="Filename.rtf", FileFormat:=wdFormatRTF End If Set oDoc = Nothing End Sub
__________________
Graham Mayor - MS MVP (Word) (2002-2019) Visit my web site for more programming tips and ready made processes www.gmayor.com |
![]() |
Tags |
docx, rtf |
Thread Tools | |
Display Modes | |
|
![]() |
||||
Thread | Thread Starter | Forum | Replies | Last Post |
xml to docx | yacov | Word | 2 | 04-20-2020 12:05 AM |
Merge a .docx into a table in existing .docx | MarkAtTheBeach | Word Tables | 3 | 10-26-2018 12:55 PM |
Docx??? | word perfect | Word | 1 | 01-18-2013 05:15 AM |
![]() |
Frustrated | Word | 3 | 12-12-2011 10:34 PM |
![]() |
ding dong | Word | 3 | 11-01-2009 12:43 PM |