Page 1 of 1

Loading a DLL

Posted: Wed Oct 17, 2007 1:56 pm
by elecuyer
Hi all,

I have a DLL that I need to call from my IA script. However, rather than simply calling a function, it must be loaded, and remain in memory for the duration of the script (or I explicitly free it.)

It appears that the CALL DLL function, loads the DLL, calls the desired function in the DLL, then unloads the DLL. How can I keep the DLL in memory until I free it (or the script terminates.)

Thanks,

-Ed Lecuyer

Posted: Wed Oct 17, 2007 3:06 pm
by Alex_Ronquillo
read the following topics in the help file, and decide which is the one you need:

Register Library and
Install Assembly

Posted: Wed Oct 17, 2007 3:35 pm
by elecuyer
Neither applies to this case.

"Register Library" is for registering/unregistering a self-registering DLL upon installation. This DLL is not being installed, I just need to run it for the duration of the script. I tried Register Library anyway, and I got the same result as if it wasn't done (IA7 - and my DLL - crashes because IA is trying to close an active DLL.)

"Install Assembly" installs and registers a .NET assembly. This is not a .NET assembly that needs to be installed/registered. It is a standard DLL that needs to remain open for the duration of the script. For fun, I tried Install Assembly anyway - and again IA7 crashed string to close my dll.

Is there another solution or am I SOL?

I have attached the DLL for reference. Call is:
~InstallAware Clipboard Data~
~Call DLL Function~
~{295DF8C3-A8F1-45F9-B004-992AD872990C}~
~$SUPPORTDIR$\\AutoRunOff.dll,MTA_AutoplayStart,void,,$~
~mIDEFunc.dll\\mEXEFunc.dll~

File Attached:

AutoRunOff.dll

Re: Loading a DLL

Posted: Mon Jul 30, 2018 2:36 am
by StarMessage
I see this is a quite old topic and wonder if some changes in IA happened in the meantime.
I wish to call functions from the SoftMeter DLL ( https://www.starmessagesoftware.com/softmeter )