M
muyBN
I used the following code in developing a macro under Word 2003 then put it
on a machine using Word 2007. Everything I've transferred from 2003 to 2007
macros has worked fine, but with the code below, 2007 gave me a message
saying the file didn't exist. Duh...that's why I'm using the Save As command,
so the file can be created. Any help on this?
ActiveDocument.SaveAs FileName:=strPath & "Mailing" & dtmFile &
".csv", 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
on a machine using Word 2007. Everything I've transferred from 2003 to 2007
macros has worked fine, but with the code below, 2007 gave me a message
saying the file didn't exist. Duh...that's why I'm using the Save As command,
so the file can be created. Any help on this?
ActiveDocument.SaveAs FileName:=strPath & "Mailing" & dtmFile &
".csv", 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