Unloading the DLL

To unload the DLL when you are finished with it, call the FreeLibrary function of the library object. For example:

Call sbmLib.FreeLibrary()

You do not need to pass any parameters to FreeLibrary() because it attempts to free the library that was specified by SetLibraryName().