home *** CD-ROM | disk | FTP | other *** search
/ NetNews Usenet Archive 1992 #30 / NN_1992_30.iso / spool / comp / os / mswindo / programm / misc / 4348 < prev    next >
Encoding:
Text File  |  1992-12-21  |  1.2 KB  |  32 lines

  1. Newsgroups: comp.os.ms-windows.programmer.misc
  2. Path: sparky!uunet!zaphod.mps.ohio-state.edu!saimiri.primate.wisc.edu!ames!sun-barr!cs.utexas.edu!wotan.compaq.com!twisto.eng.hou.compaq.com!sword.eng.hou.compaq.com!mccreary
  3. From: mccreary@sword.eng.hou.compaq.com (Ed McCreary)
  4. Subject: Re: Force DLL to unload
  5. Message-ID: <1992Dec18.144024.14800@twisto.eng.hou.compaq.com>
  6. Sender: news@twisto.eng.hou.compaq.com (Netnews Account)
  7. Organization: Compaq Computer Corp.
  8. References: <DEREKL.92Dec18100741@watson.harlqn.co.uk>
  9. Distribution: comp
  10. Date: Fri, 18 Dec 1992 14:40:24 GMT
  11. Lines: 19
  12.  
  13. In article <DEREKL.92Dec18100741@watson.harlqn.co.uk> derekl@harlqn.co.uk (Derek Law) writes:
  14. >Does anybody know how to FORCE Windows 3.1 to unload a DLL? I'm
  15. >developing a DLL, but every time I change it I have to quit and
  16. >restart Windows - otherwise Windows complains that the file is "still
  17. >in use" and so write protected.
  18. >
  19.  
  20. How are you loading it?  Try this...
  21.  
  22. HINSTANCE    hLib;
  23.  
  24. hLib = LoadLibrary("MY.DLL");
  25. ....program code....
  26. FreeLibrary(hLib);
  27.  
  28. --
  29. Ed McCreary                                               ,__o
  30. mccreary@sword.eng.hou.compaq.com                       _-\_<,
  31. "If it were not for laughter, there would be no Tao."  (*)/'(*)
  32.