Tek-Tips is the largest IT community on the Internet today!

Members share and learn making Tek-Tips Forums the best source of peer-reviewed technical information on the Internet!

  • Congratulations gkittelson on being selected by the Tek-Tips community for having the most helpful posts in the forums last week. Way to Go!

Adding libraries to Access XP Object Browser

Status
Not open for further replies.

putz

MIS
Jan 19, 2003
3
CA
I'm trying to use some Excel objects in Access XP. My VB/VBA books tell me I can use the following declaration to dimension a Excel Object:

Dim xapp As Excel.Application

When I do, I get:
Compile Error: User-defined type not defined

When I go to the object browser, I cannot find the Excel Library. I'm pretty sure that since I can't see the Excel Object Lib, then I would get this error. Problem is, I am new to VBA (used to 'C' alot many years ago) and do not know how to instruct VBA in Access to include the Excel Object Lib

Any help is greatly appreciated.

Thanks

 
Open up some code or the immediate window and hit Tools|References. There's a huge list of libraries you can add. Find the right Excel library and click there.

Also, you can use an access database (or a lot of other things) as a library, by using the browse button.

Once you do that, you'll be all set to use the objects etc. from the library, and it will be present in the Object Browser.

Hope this is helpful.

Jeremy =============
Jeremy Wallace
AlphaBet City Dataworks

Take a look at the Developers' section of the site for some helpful fundamentals.
 
Thanks a million! It worked like a charm - well, it did after I took it out of debug mode :)
 
Status
Not open for further replies.

Part and Inventory Search

Sponsor

Back
Top