cancel
Showing results for 
Show  only  | Search instead for 
Did you mean: 
Daniel_Dority
Level 6

Add a DLL and call a function

Hey there,

I want to add a DLL to the setup and then call it on the OnAppSearch() function. Not during the actual install process.

Perferably an example on where to add the file, how to call the dll, and pass / get results.

Where can I find documentation on how to do that?

thanks
Labels (1)
0 Kudos
(3) Replies
Daniel_Dority
Level 6

Alright I found the first part:

Behavior and Logic > Support Files/Billboards > Language Independent

And to call that sucker, you use SUPPORTDIR to get the correct path, not SourceDir.


Now can I reference a DLL that I created in C# and call a function and return some data? If so, how would I go about doing that?
0 Kudos
RobertDickau
Flexera Alumni

For a C-callable DLL in an InstallScript project, you'll want to look in the help and these forums for UseDLL and UnUseDLL, along with how to prototype an exported DLL function.

For calling C# methods in InstallScript, please look up DotNetCoCreateObject (and search older forums for CoCreateObjectDotNet).
0 Kudos
Daniel_Dority
Level 6

Brilliant!

I got it all working nicely.

Thanks for the help!
0 Kudos