Results 1 to 5 of 5

Thread: error calling dll from installscript

  1. #1
    Join Date
    Nov 2002
    Posts
    32

    error calling dll from installscript

    for some reason I'm getting error 0x80040710 (-2147219705) when trying to call a function in a DLL. Note that I get this error on the actual call, not on the UseDLL line....execution doesn't make it into the function in the DLL. Anyone have any idea what this error could be? I've searched on google and in this site with no luck....

  2. #2
    Join Date
    Oct 2001
    Location
    Here and there
    Posts
    16,233
    Could you post the InstallScript prototype and the C/C++ prototype of your DLL function?
    Robert Dickau - This and That - Flexera Software

    Want help? See Windows Installer white papers, training courses, newsletters, HelpNet, forum search, Knowledge Base, ...
    Want more help?
    See our InstallTalk blog.
    Want even more help? See our relatively new Advanced Windows Installer (MSI) training course.

  3. #3
    Join Date
    Nov 2002
    Posts
    32
    surely

    InstallScript:
    prototype STDCALL BOOL InstallationBridge.ConfigureGentle(POINTER, POINTER, POINTER);

    C:
    bool __stdcall ConfigureGentle(char const *fileName, char const *provider, char const *connectionString);


    I've tried exporting with __declspec(dllexport) and with a def file, both give the same thing, and I've checked the DLL with depends.exe and the name isn't being mangled...

  4. #4
    Join Date
    Oct 2001
    Location
    Here and there
    Posts
    16,233
    Hmmmm... In the InstallScript prototype, perhaps replace POINTER with BYVAL STRING?
    Robert Dickau - This and That - Flexera Software

    Want help? See Windows Installer white papers, training courses, newsletters, HelpNet, forum search, Knowledge Base, ...
    Want more help?
    See our InstallTalk blog.
    Want even more help? See our relatively new Advanced Windows Installer (MSI) training course.

  5. #5
    Join Date
    Nov 2002
    Posts
    32
    actually...thanks for the help but I believe I've figured it out. My DLL is a managed C++ DLL which I am using as a bridge so I can use .NET objects in the installer. The problem is that when it's trying to load a .NET assembly (from within the DLL) it can't find the assembly. I've got both the DLL and the assembly in the supportdir, but it appears it won't find the assembly unless it is in the same directory as setup.exe. So I'm going to try explicitly loading it into the bridge DLL and using reflection to access it....thx for your help

Posting Permissions

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