View Full Version : Custom Action DLL

01-26-2003, 01:56 AM
I have not been successful in getting a custom action dll to load. I keep getting an error message: "Cannot find the entry point of function 'RevealID', make sure it is exported." I have attached my source file (it is written in Delphi).
I'm using ISE 4.0, Delphi 4 & 7, Windows 2000 SP3, and my custom dll is triggered to launch after the "setup progress dialog".

01-27-2003, 01:42 PM
This is because Delphi's "Export" function (which I assume you have done) doesn't make Windows Installer recognize that function as part of the DLL. The workaround is to manually create a .def file with the following (put the name of your DLL instead of "CheckForIE"):


RevealID @1

01-27-2003, 08:03 PM
I use BCB 5 and not Delphi but I think that what I have had to do to get my DLL's working properly will be the same for you. I use the new signature (hMsi handle passed). My problem was that the names of the functions were mangled (OOP compiler) to find out the mangled name and use that in InstallShield Express, find the impdef.exe (probably in the bin directory) put a copy in the directory of your dll project. At the dos prompt in the project directory type impdef yourproject.def yourproject.dll. This will tell you what the mangled names of your functions are just open the file yourproject.def. Use these in the Custom Action area. For example in my dll the function name is InstallService the exported (mangled name) is @InstallService$qqsul. This is what I call from InstallShield Express and everything works fine! I also add the def file from impdef (yourproject.def) to my dll project.

My def file looked something like this


@AddService$qqsul @1 ; __stdcall AddService(unsigned long)

there were other functions but this gives you the idea. You need to run impdef.exe to find out what the mangled name is.

Hope that helps (HTH)


01-28-2003, 03:18 AM
That makes sense. However, my DLL already exports the following:

RevealID @1 ; RevealID

I know Delphi use to have a free download, so do you know anybody there at InstallShield that can get my DLL to work? All they have to do is change the extension of dosndll.txt to .dpr and compile using any version of Delphi.