Results 1 to 3 of 3

Thread: GetObject {Resolved}

Threaded View

  1. #1

    Thread Starter
    New Member
    Join Date
    Sep 2004
    Posts
    4

    Resolved GetObject {Resolved}

    I have created a dll in VB 6.0. I am using the GetObject method to get the path of the excel file that called the dll. However, I have just realized that if there are two different excel files open, this will return the first file path that was opened, not necessarily the file that called the dll. Is there another method that I can use...like GetThisObject, or something similar?

    Below is an example of what I am using.


    Dim ExcelTest As Excel.Application

    Set ExcelTest = GetObject(, "Excel.Application")


    In addition, when I try to use this method in a simular method in Access 97, I get a "Run-Time Error '429': ActiveX component can't create object" error. However, this will work in Access 2000.

    The code being used for the Access application is

    Dim AccessTest As Access.Application

    Set AccessTest = GetObject(, "Access.Application")


    Any ideas??

    Thanks!
    Last edited by thedude1972; Jan 24th, 2005 at 04:30 PM.

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •  



Click Here to Expand Forum to Full Width