
Opening an Excel template from within Word VBA
I have some automation to MS Word 2000 for creating faxes, etc from
templates. I now need be able to open an Excel template from with the Word
VBA program but have been unsuccessful. I added the Excel 9.0 reference to
the Word VBA project and am trying to use the following line of code to open
the spreadsheet...
Excel.Workbooks.Open (strPath & "\SomeSpreadsheet.xlt")
This line runs without generating any errors however I never see the Excel
template.
Also, I want to open the template as a new spreadsheet rather than
opening the original .XLT file for editing. I've done this with word
templates using the following code but I'm unsure how to perform the same
operation on an Excel template instead...
Documents.Add Template:=strPath & "\SomeWordTemplate.DOT",
newtemplate:=False, DocumentType:=0
Any info would be greatly appreciated.
Rick