D
dblaze1
I have a template that creates a letter. There is VBA code that reads
a text file for a database key value then uses that key in an ODBC
lookup to populate fields in the letter (name, address, etc) from a
database. All of this works fine if I start Word, select File/New/
Template on my computer and choose the template.
I need to do something very similar but in a batch environment where I
start up Word from the command line and tell it to use this template.
The key value in the file will be present before I start Word (my
batch script will create a file with the same name but different
values for each execution of Word). When attempt this with the
following command line:
winword.exe /t"c:\documents and settings\username\application data
\microsoft\templates\template.dot",
I get the following error (Word starts then displays the error):
There is insufficient memory or disk space. Close extra windows and
save your work".
I've tried this on my laptop and get the same results. Can anyone
shed any light on what may be going on? I'm at a loss.
Thanks in advance,
Doug
a text file for a database key value then uses that key in an ODBC
lookup to populate fields in the letter (name, address, etc) from a
database. All of this works fine if I start Word, select File/New/
Template on my computer and choose the template.
I need to do something very similar but in a batch environment where I
start up Word from the command line and tell it to use this template.
The key value in the file will be present before I start Word (my
batch script will create a file with the same name but different
values for each execution of Word). When attempt this with the
following command line:
winword.exe /t"c:\documents and settings\username\application data
\microsoft\templates\template.dot",
I get the following error (Word starts then displays the error):
There is insufficient memory or disk space. Close extra windows and
save your work".
I've tried this on my laptop and get the same results. Can anyone
shed any light on what may be going on? I'm at a loss.
Thanks in advance,
Doug