%DLL_CLOSE
WTSupported in traditional Synergy on Windows
|
WNSupported in Synergy .NET on Windows
|
USupported on UNIX
|
|
status = %DLL_CLOSE(dll_handle)
Return value
status
An integer value of 1 if %DLL_CLOSE is successful. If unsuccessful, the error $ERR_DLLCLSERR is generated. (i)
Arguments
dll_handle
The handle of the DLL, as returned from %DLL_OPEN. (i4)
The %DLL_CLOSE function closes a DLL that was opened with %DLL_OPEN.
Make sure you close each DLL only once for each DLL_OPEN. If you close a DLL twice in one part of an application, the rest of the application may assume the DLL is still open and available but can no longer access it. This situation will leave the rest of the application in an unstable state. Pay particular attention whenever a system DLL (for example, user32.dll on Windows) is accessed, because the runtime also uses these DLLs.
Each DLL opened by a Synergy application should be closed with %DLL_CLOSE before the Synergy application is exited. If %DLL_CLOSE is not called and the customer does a program chain, the resources are not freed. Calls across program chains can use the same DLL handle.
When the runtime ends, whether normally or abnormally, it automatically closes all open DLLs.
Examples
See %DLL_CALL Examples.