View Single Post
 
Old 08-24-2019, 08:38 PM
gmayor's Avatar
gmayor gmayor is offline Windows 10 Office 2016
Expert
 
Join Date: Aug 2014
Posts: 4,106
gmayor has much to be proud ofgmayor has much to be proud ofgmayor has much to be proud ofgmayor has much to be proud ofgmayor has much to be proud ofgmayor has much to be proud ofgmayor has much to be proud ofgmayor has much to be proud of
Default

How about the following. Change the font name as appropriate.

Code:
Sub SaveUnicode()
Dim strName As String
Const strFont As String = "Times New Roman"    'the font to apply
    If Len(ActiveDocument.Path) > 0 Then
        strName = Left(ActiveDocument.FullName, InStrRev(ActiveDocument.FullName, ".") - 1) & ".txt"
    Else
        strName = Options.DefaultFilePath(wdDocumentsPath) & "\MyDocument.txt"
    End If
    ActiveDocument.Range.Font.Name = strFont
    ActiveDocument.SaveAs2 FileName:=strName, FileFormat:=wdFormatUnicodeText
End Sub
__________________
Graham Mayor - MS MVP (Word) (2002-2019)
Visit my web site for more programming tips and ready made processes www.gmayor.com
Reply With Quote