ExcelBanter

ExcelBanter (https://www.excelbanter.com/)
-   Excel Programming (https://www.excelbanter.com/excel-programming/)
-   -   TYPE Library issues. (https://www.excelbanter.com/excel-programming/337771-type-library-issues.html)

shishi

TYPE Library issues.
 
Hi ,

I have started on a project to generate ms-word documents from excel
sheet. The vba code starts something like below.

Dim oWrd As Word.Application
Dim oDoc As Word.Document
Set oWrd = New Word.Application

I am getting an error from the first line. The error is "complie error:
User-Defined type not defined". I checked Tools-References and found
that the following are already checked.
1. Visual Basic for applications
2. Microsoft Excel 9.0 Object Library
3. OLE Automation
4. Microsoft Office 9.0 Object Library
etc.

What could be that I am doing wrong? Please help. Thanks in advance
for your suggestion.

shishi


Jim Rech

TYPE Library issues.
 
Set a reference to Word.

--
Jim
"shishi" wrote in message
ups.com...
Hi ,

I have started on a project to generate ms-word documents from excel
sheet. The vba code starts something like below.

Dim oWrd As Word.Application
Dim oDoc As Word.Document
Set oWrd = New Word.Application

I am getting an error from the first line. The error is "complie error:
User-Defined type not defined". I checked Tools-References and found
that the following are already checked.
1. Visual Basic for applications
2. Microsoft Excel 9.0 Object Library
3. OLE Automation
4. Microsoft Office 9.0 Object Library
etc.

What could be that I am doing wrong? Please help. Thanks in advance
for your suggestion.

shishi





All times are GMT +1. The time now is 11:42 PM.

Powered by vBulletin® Copyright ©2000 - 2025, Jelsoft Enterprises Ltd.
ExcelBanter.com