1
I have a Windows XP netbook and it is protected with a password. I want to be able to control the time other people spend on the computer, so whenever anyone logs in I want the computer to automatically log off after two hours.
1
I have a Windows XP netbook and it is protected with a password. I want to be able to control the time other people spend on the computer, so whenever anyone logs in I want the computer to automatically log off after two hours.
1
How about executing logon script (help: To assign user logon scripts) with following code:
ping 127.0.0.1 -n 7200 -w 1000
shutdown /l /f
This script will wait 7200 seconds (2 hours) and then force to log off.
I think this is the most useful thing to do because XP task schedules can't have a delay before they run so a "helper program" or script will have to do. This answer will cause a command prompt window to be on screen for 2hrs that can be closed by the user - thus circumventing the logoff script's process - but due to XP's lack of features there's nothing much more you can do... Windows 7, howevere, DOES have the ability to delay the task start. – Kinnectus – 2015-03-11T08:57:36.750
In Windows Vista, there are lock / unlock events, which can be used to run the script without command prompt window: In Windows 7, How to query times, when the computer was locked?. I don't have Windows XP, to check if there are similar events available.
– Virus_7 – 2015-03-11T08:59:32.597That, again, is a little more advanced for XP (I think?!)... and even then, it would be no different to the script you've written... a "logon" event would still need to have a script run for 2hrs... a "logoff" event would be useless because the user will be logged off lol... – Kinnectus – 2015-03-11T09:01:24.857
You can create Start a program action, while creating task in Task Scheduler (
Win + R
>taskschd.msc
) – Virus_7 – 2015-03-11T09:06:07.037