dcsimg
Results 1 to 3 of 3

Thread: Automation Error when creating instance of Interop object from VB6 on Windows 10

  1. #1

    Thread Starter
    Randalf the Red honeybee's Avatar
    Join Date
    Jun 2000
    Location
    off others' brains
    Posts
    4,345

    Automation Error when creating instance of Interop object from VB6 on Windows 10

    So we have moved our code to Windows 10 (home) with VB Professional and compiled it successfully (after making sure all the missing reference files got copied to the SysWow64 folder and other locations, registered them etc).

    There are a couple of interop libraries that the code uses. Trouble is when the code executes, it crashes with an Automation Error: System cannot find the specified file error when creating an instance of an interop object. Since the interops have been added to the references using the TLB files, I assume the system is unable to locate the DLL from the TLB file. How to fix this?

    To give a background, I have tried all sorts of regasm variations (with / without codebase, with / without TLB and even building the interop project from VS.Net). The references point to the correct files in the correct locations. The code compiles just fine. It only fails at runtime.

    Also the VB6 exe (the compiled version of the code) runs absolutely fine - so it is able to create instances of the Interop objects fine. But when the code is run from within VB6 development environment, the interop instance creation fails with automation error.

    What gives?
    I am not a complete idiot. Some parts are still missing.
    Check out the rtf-help tutorial
    General VB Faq Thread
    Change is the only constant thing. I have not changed my signature in a long while and now it has started to stink!
    Get more power for your floppy disks. ; View honeybee's Elite Club:
    Use meaningfull thread titles. And add "[Resolved]" in the thread title when you have got a satisfactory response.
    And if that response was mine, please think about giving me a rep. I like to collect them!

  2. #2
    PowerPoster
    Join Date
    Jun 2015
    Posts
    2,224

    Re: Automation Error when creating instance of Interop object from VB6 on Windows 10

    have you tried running VB6 IDE un-elevated?

  3. #3

    Thread Starter
    Randalf the Red honeybee's Avatar
    Join Date
    Jun 2000
    Location
    off others' brains
    Posts
    4,345

    Re: Automation Error when creating instance of Interop object from VB6 on Windows 10

    Quote Originally Posted by DEXWERX View Post
    have you tried running VB6 IDE un-elevated?
    You mean without admin privileges? To be honest, no. But just for the heck of it, I shall give it a try. Not sure it will work, though.
    I am not a complete idiot. Some parts are still missing.
    Check out the rtf-help tutorial
    General VB Faq Thread
    Change is the only constant thing. I have not changed my signature in a long while and now it has started to stink!
    Get more power for your floppy disks. ; View honeybee's Elite Club:
    Use meaningfull thread titles. And add "[Resolved]" in the thread title when you have got a satisfactory response.
    And if that response was mine, please think about giving me a rep. I like to collect them!

Tags for this Thread

Posting Permissions

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



Featured


Click Here to Expand Forum to Full Width