home *** CD-ROM | disk | FTP | other *** search
/ NetNews Usenet Archive 1992 #20 / NN_1992_20.iso / spool / comp / os / mswindo / programm / tools / 932 < prev    next >
Encoding:
Internet Message Format  |  1992-09-11  |  1.7 KB

  1. Path: sparky!uunet!spool.mu.edu!yale.edu!ira.uka.de!smurf.sub.org!flatlin!ovum!cmm!cm
  2. From: cm@cmm.ovum.ka.sub.org (Christoph Mueller)
  3. Newsgroups: comp.windows.ms.programmer,comp.os.ms-windows.programmer.tools
  4. Subject: Re: Restart Windows from within, resource garbage collection
  5. Keywords: ExitWindows, Restart
  6. Message-ID: <N3muqB2w165w@cmm.ovum.ka.sub.org>
  7. Date: Wed, 09 Sep 92 21:38:22 CED
  8. References: <1992Sep8.174740.24723@jarvis.csri.toronto.edu>
  9. Distribution: world
  10. Organization: Christoph's PC, Karlsruhe, Germany
  11. Lines: 30
  12.  
  13. jinli@dgp.toronto.edu (Jin Tonic Li) writes:
  14.  
  15. >
  16. > 1. How do I restart Windows in a Windows application that is currently runnin
  17. >    The control panel can do this when the virtual memory size is changed.
  18. >
  19. Try out
  20. ExitWindows (EW_REBOOTSYSTEM, 0)    to terminate Windows and reboot
  21. ExitWindows (EW_RESTARTWINDOWS, 0)  to terminate and restart Windows
  22.  
  23. As far as I know, in Windows 3.0 those were undocumented features, the
  24. value of EW_RESTARTWINDOWS is 66 (0x42).
  25.  
  26. As I just saw in the manual (3.1 but it says that the function is from Win 3.0)
  27. was this function  ExitWindowsExec  which can be used to exit windows, run
  28. an MS-DOS program and restart Windows again.  Just in case the above is not
  29. enough.
  30.  
  31. >
  32. > 2. Is there a way to clean up dangling resources, e.g. GDI, that are left beh
  33. >    by other tasks?  Windows' own screen saver always hogs resources this way.
  34. >
  35.  
  36. The only way definite way to do this which I know of is the above: exit and
  37. restart windows.  Does anybody know better ways?
  38.  
  39. ---Christoph, Germany    ---   cm@cmm.ovum.ka.sub.org
  40. -------------------------------------------------------------------------
  41. Dysklaemours?  What's that?  How do you spell that?  Do I need that?
  42. I  *AM*  the  SYSTEM,  the  EMPLOYER,  and  the  ORGANIZATION  !!
  43.