-
Deleting a locked DLL
This might sound like a strange problem... but here goes:
I have a VB program which uses a DLL that I made. When the program finishes it is supposed to delete the DLL. Unfortunately the program locks access to the DLL when it first uses it.
Is the a way I can unlock it?
-
Close the file handle to the DLL.
-
... could you give me an idea of how?
-
... no then. anyone else?
-
how does your program use the dll? is it a reference? it is probably going to be pretty hard to delete it in the program that references it.. you may want to try using late binding instead and destroy all objects before closing the app.. that should work
-
The DLL just has some functions in it. These are declared in a Class Module, using the normal "Private Declare Sub... " function declaration.
Can you give me an example of how I might use the technique that you described?
-