L
Laphan
Hi All
I know this is a Word VBA group, but because the VBA DocProperties command
to set the SaveAs Filename doesn't actually work when you run the command
from VB6, my VB6 app generates pre-populated MS Word docs and I want to
pre-populate the Save filename box as well without saving the actual doc, it
appeared that my only option was to use:
WordBasic.SetDocumentProperty "Title", 0, strWordFilename, 1
This works fine on my first run, but if the user clicks the button on my app
again (they may do this several times in one session) my app generates the
error message:
The remote server machine does not exist or is unavailable error 462
If I take out this single line of code then everything works fine again, ie
I can generate thousands of new Word docs, but obviously my bespoke SaveAs
filename won't appear.
It's as if I need to kill the WordBasic entity so that each time the button
is clicked WordBasic starts afresh.
Any ideas?
I know this is a Word VBA group, but because the VBA DocProperties command
to set the SaveAs Filename doesn't actually work when you run the command
from VB6, my VB6 app generates pre-populated MS Word docs and I want to
pre-populate the Save filename box as well without saving the actual doc, it
appeared that my only option was to use:
WordBasic.SetDocumentProperty "Title", 0, strWordFilename, 1
This works fine on my first run, but if the user clicks the button on my app
again (they may do this several times in one session) my app generates the
error message:
The remote server machine does not exist or is unavailable error 462
If I take out this single line of code then everything works fine again, ie
I can generate thousands of new Word docs, but obviously my bespoke SaveAs
filename won't appear.
It's as if I need to kill the WordBasic entity so that each time the button
is clicked WordBasic starts afresh.
Any ideas?