C
Cory
The situation:
Using Office XP
I have one Excel document and one Word document template in this operation.
The concept of operation is that Excel will create a word document off of
the template, and fill in several fields that are on the resulting document
with values from the worksheet. Everything works fine until I try to
actually set data into the fields.
Even when in the immediate window in Word, I can make a statment like:
ThisDocument.Fields("Text1").Result.Text = "Something" and it returns Type
mismatch.
I have tried setting the variables to Variants so that they can be whatever
it needs, setting them as ranges and using the .result property, setting as
strings, etc. Nothing works.
I know that it is supposed to work because I have done it previously. I
just can't remember what I did differently... Any thoughts?
Cory
Using Office XP
I have one Excel document and one Word document template in this operation.
The concept of operation is that Excel will create a word document off of
the template, and fill in several fields that are on the resulting document
with values from the worksheet. Everything works fine until I try to
actually set data into the fields.
Even when in the immediate window in Word, I can make a statment like:
ThisDocument.Fields("Text1").Result.Text = "Something" and it returns Type
mismatch.
I have tried setting the variables to Variants so that they can be whatever
it needs, setting them as ranges and using the .result property, setting as
strings, etc. Nothing works.
I know that it is supposed to work because I have done it previously. I
just can't remember what I did differently... Any thoughts?
Cory