Set a break point in your DllCanUnloadNow function.
A call to DllCanUnloadNow determines whether the DLL from which it is exported is still in use. A DLL is no longer in use when it is not managing any existing objects (the reference count on all of its objects is 0). If it is called, then something wrong inside this function, otherwise something wrong outside the function, usually with the reference count.
好象没有正在用那个DLL的进程,我一直很奇怪。