E
Ed from AZ
I'm trying to port working Word VBA code into an Excel VBA module.
Because I don't know which version of Word my users have, I'm writing
it as late-binding code (everything Word is Dim'd as Object). I think
'most everything is going okay so far (we'll find out when I smoke
test!), but I'm wondering about certain Word objects that use methods
and properties not found in Excel.
My question is: when the Word Application object is set and the other
Word objects (docs and ranges) are set, will they be able to access
all the properties and methods of the Word object as if they were
early-bound?
For instance:
rngDoc.Find.Execute _
FindText:="MyText"
Excel Find does not have the Execute method nor the FindText property.
and
rngDoc.MoveEnd Unit:=wdParagraph
likewise has no Excel equivalent.
Should this compile and run okay? Or am I going to have to find new
ways to write this that are compatible with a late-binding routine?
Ed
Because I don't know which version of Word my users have, I'm writing
it as late-binding code (everything Word is Dim'd as Object). I think
'most everything is going okay so far (we'll find out when I smoke
test!), but I'm wondering about certain Word objects that use methods
and properties not found in Excel.
My question is: when the Word Application object is set and the other
Word objects (docs and ranges) are set, will they be able to access
all the properties and methods of the Word object as if they were
early-bound?
For instance:
rngDoc.Find.Execute _
FindText:="MyText"
Excel Find does not have the Execute method nor the FindText property.
and
rngDoc.MoveEnd Unit:=wdParagraph
likewise has no Excel equivalent.
Should this compile and run okay? Or am I going to have to find new
ways to write this that are compatible with a late-binding routine?
Ed