Article View: be.comp.programming
Article #1371Re: batch file voor afsluiten
From: Wimjan
Date: Mon, 04 Apr 2005 13:54
Date: Mon, 04 Apr 2005 13:54
44 lines
2487 bytes
2487 bytes
Peterus schreef: > Hallo specialisten > > Ik zou graag een batchfile schrijven die op een bepaald uur de gebruiker > afsluit. > Maar vooreerst zou de gebruiker een waarschuwing moeten krijgen dat hij zijn > werk moet opslaan. > Dus eerst de melding en dan een 20 tal seconden later de pc afsluiten. > Kan iemand mij helpen want het lukt mij niet.(WIN XP HOME) > Wel, da's toch een simpele combinatie van de Task Scheduler (Taakplanner in het Nederlands?) met het programma shutdown.exe? Uit een andere post op Usenet: <citaat uit bericht c59up0tongkblti517g75ajo8n7oas54m8@4ax.com> C:\Windows\ System32\Shutdown.exe, [... append the command line switch -l (to log off), -s (to shutdown), or -r (to reboot). If you also add the switch �t xx (where xx is a number of seconds), Shutdown.exe will display a warning and count down the specified number of seconds before activating. You can specify a comment to be displayed with the warning by adding the switch -c "Your text". The countdown behavior is particularly useful if the shutdown program is launched through the Scheduled Tasks applet. For example, a library computer might be scheduled to shut down 10 minutes before closing, with a 60-second warning. Once the countdown has begun, the only way to stop it is to launch the program again with the -a (for abort) switch on its command line. </citaat> Hoe je niets aan te programmeren, zit gewoon standaard in XP. > Dank bij voorbaat > Graag gedaan. Groet, Wimjan -- Sleet is van vroeger, tegenwoordig gaat alles kapot.
Technical Details
Message-ID:
<MPG.1cbb6584a30e3c97989899@news.leidenuniv.nl>Path:
arc1-ca.pugleaf.net!g2news1.google.com!news1.google.com!proxad.net!fr.ip.ndsoftware.net!feeder.enertel.nl!nntpfeed-01.ops.asmr-01.energis-idc.net!surfnet.nl!leidenuniv.nl!not-for-mailReferences:
<d2r77g$vk$1@nl-news.euro.net>Show Full Headers
Complete Article Headers
X-Google-Thread: fcea4,cfaa991edfb64885 X-Google-Attributes: gidfcea4,public X-Google-Language: DUTCH,ASCII Path: arc1-ca.pugleaf.net!g2news1.google.com!news1.google.com!proxad.net!fr.ip.ndsoftware.net!feeder.enertel.nl!nntpfeed-01.ops.asmr-01.energis-idc.net!surfnet.nl!leidenuniv.nl!not-for-mail From: news@inventio.nl (Wimjan) Newsgroups: be.comp.programming Subject: Re: batch file voor afsluiten Date: Mon, 4 Apr 2005 15:54:29 +0200 Organization: Universiteit Leiden Lines: 44 Message-ID: <MPG.1cbb6584a30e3c97989899@news.leidenuniv.nl> References: <d2r77g$vk$1@nl-news.euro.net> NNTP-Posting-Host: s15046.leidenuniv.nl Content-Type: text/plain; charset=ISO-8859-1 X-Trace: mercury.leidenuniv.nl 1112623053 13637 132.229.150.46 (4 Apr 2005 13:57:33 GMT) X-Complaints-To: usenet@mercury.leidenuniv.nl NNTP-Posting-Date: Mon, 4 Apr 2005 13:57:33 +0000 (UTC) X-Newsreader: MicroPlanet Gravity v2.12