How do I change a file type from .dotx to .docx in VBA? I can save it with the .docx format but it's actually still saving as a template.
Currently, I have the following code:
'set doc name to contract number, document number, task order, and CDRL item number
docName = (CStr(frmName.Contract_Number.Column(1))) & "-" & txtDOTO & _
"-" & (CStr(frmName.CDRL_Number.Column(1))) & "_" & (CStr(frmName.Document_Number)) & _
"_" & (CStr(frmName.Document_Revision)) & "_Disposition" & ".docx"
fullName = CurrentProject.Path & "" & docName 'set fullName to path plus docName
wrdDoc.SaveAs fileName:=fullName
I know there's a way to set the file type when saving it but so far, the stuff I've found just confuses me more.
Thanks,
Dar
Currently, I have the following code:
'set doc name to contract number, document number, task order, and CDRL item number
docName = (CStr(frmName.Contract_Number.Column(1))) & "-" & txtDOTO & _
"-" & (CStr(frmName.CDRL_Number.Column(1))) & "_" & (CStr(frmName.Document_Number)) & _
"_" & (CStr(frmName.Document_Revision)) & "_Disposition" & ".docx"
fullName = CurrentProject.Path & "" & docName 'set fullName to path plus docName
wrdDoc.SaveAs fileName:=fullName
I know there's a way to set the file type when saving it but so far, the stuff I've found just confuses me more.
Thanks,
Dar