Dim w As New Word.Application
Dim doc As Word.Document
filePath = "c:\..\test.doc"
filePathTxt = "c:\..\test.txt"
Set doc = w.Documents.Open(filePath)
doc.SaveAs FileName:=filePathTxt, FileFormat:=wdFormatText, _
LockComments:=False, Password:="", AddToRecentFiles:=True, WritePassword _
:="", ReadOnlyRecommended:=False, EmbedTrueTypeFonts:=False, _
SaveNativePictureFormat:=False, SaveFormsData:=False, SaveAsAOCELetter:= _
False, Encoding:=1252, InsertLineBreaks:=False, AllowSubstitutions:=False _
, LineEnding:=wdCRLF
|