building a new dll.

Hello, I'm building a new .dll (an new .lib) with some meshing tools.

The first time my OS (Windows98) calls the .dll to run the main application (a very simple test with Draw), everything works. Then I rebuild my .dll (and my .lib) with some changes. I try to run my main application but it crashes. I think that Windows98 still uses the first .dll which is already loaded in memory because if I wait a long time or if I reboot my system, my application runs (with the new .dll).

How can I force my system to load the new .dll ?

Thanks for your help.

David & Guillaume.

Jean-Claude Demosthenidy's picture

You need to make sure your DLL is unloaded first, i.e. that it's not locked in memory. There is a counter in each DLL (a state variable) that tells the OS that the DLL is locked in. You need to unload your DLL cleanly, even if the app blows...