There are several ways to convert doc file to docx file automatically. The simplest and fastest way would be to use
Wordconv.exe is included if you install either Office after 2007 or download and install the Compatibility Pack from Microsoft.
You can convert from .doc to .docx easily using the following command:
"C:\Program Files\Microsoft Office\Office15\wordconv.exe" -oice -nme <input file> <output file>
<input file> and
<output file> need to be fully qualified path names.
The command can be easily applied to multiple documents using
for %F in (*.doc) do "C:\Program Files\Microsoft Office\Office15\wordconv.exe" -oice -nme "%F" "%Fx"
Other methods, such as
automate Word or Microsoft’s Office File Converter (
ofc.exe) are much more complicated than