# Function Reference

DllClose

Closes a previously opened DLL.

DllClose ( dllhandle )

Parameters

dllhandle | The handle of a dll, as returned by a previous call to DllOpen.

Return Value

None.

Remarks

If dllhandle is invalid, an AutoIt runtime error will be thrown, and the script will terminate!
Upon termination, AutoIt automatically closes any dlls it opened but calling DllClose is still a good idea.

Related

DllCall, DllOpen

Example

$dll = DllOpen("user32.dll")
$result = DllCall($dll, "int", "MessageBox", "hwnd", 0, "str", "Some text", "str", "Some title", "int", 0)
DllClose($dll)