Call FreeLibrary() with the module handle of the dll which you wish to unload.

You can get the module handle by calling GetModuleHandle with the name of the module as a parameter.