Quoting Shidai Liu <[EMAIL PROTECTED]>: > Any one know how to make a shutdown, restart, logoff call in windows os > like 98, 2000 and xp?
Try this: win32api.InitiateSystemShutdown(None, 'Kaboom!', 2000, False, False) Parameters: 1. Computer to shutdown (None for lcoalhost) 2. Message to display. 3. Time in ms to display message (0 for no message). 4. Kill programs (False to allow user a chance to save their work). 5. Reboot or shutdown. If you are doing win32 programming, I strongly recommend Mark Hammond's book! (since that's where I got this information) Note that I have not tested this (in particular, it is possible I have the orientation of the two boolean parameters wrong). -- John. _______________________________________________ Tutor maillist - Tutor@python.org http://mail.python.org/mailman/listinfo/tutor