How can I...auto log off after xx minutes idle

dockster

New member
Member
Local time
10:51 PM
Messages
63
I am running 5 Windows 7 machines in condominium building. We just upgraded from old machines running WinXP to new ones with Windows 7 Home Premium 64 bit.

Previously, I was successfully able to install the winexit.scr from the WinNT resource kit and modify the appropriate registry permissions to get it to work.

I tried installing the same way on Win 7 and can't get it to work. Keep getting the registry error referenced in this MS Support article. Is it just me or does this not work on Windows 7?

I also tried setting up a task via task scheduler using shutdown.exe /l when idle for 15 minutes. But I can't get it to run with I append the /c "comment" or /t xxx time before log out. That would be another solution, but I would like to give users a 2 minute warning before it logs them out. When i try running 'shutdown /l /t 120' it just displays the shutdown help info. Same thing if I try the /c toggle. 'shutdown /l' works but instantly logs you off.

Any and all help is appreciated. I don't care which way I get it to work, but would like to get something working that accomplishes:

1) Logs out current user after a specified idle time
2) Displays some sort of message to user
3) Gives user ~ 2 minutes to save work, etc, or just move the mouse (winexit allowed for a 'cancel' button so if someone was there they could cancel the log off -- this would be the ideal situation)

Thanks.
 

My Computer My Computer

At a glance

Windows 7AMD Turion X2 RM-72 2.10 GHz Dual-Core Mobile...4GBATI Radeon HD 3200 Graphics RS780M
Computer Manufacturer/Model Number
Hewlett Packard dv4-1222nr
OS
Windows 7
CPU
AMD Turion X2 RM-72 2.10 GHz Dual-Core Mobile Processor
Memory
4GB
Graphics Card(s)
ATI Radeon HD 3200 Graphics RS780M
Monitor(s) Displays
14.1" LCD
Hard Drives
250GB (5400RPM)
Internet Speed
3.0 MBPS (down) / 1.0MBPS (up)

My Computer My Computer

At a glance

Windows 7 Ultimate x64 SP1Core i7 920 (D0) @ 4Ghz, *26c idle *65c full ...12GB DDR3 Corsair Dominator -CMD12GX3M6A1600C...Zotac Geforce GTX 770
Computer type
PC/Desktop
Computer Manufacturer/Model Number
Airbot 2.0
OS
Windows 7 Ultimate x64 SP1
CPU
Core i7 920 (D0) @ 4Ghz, *26c idle *65c full load on air
Motherboard
Asus P6X58D Premium - Sata 6Gb/s - USB 3.0
Memory
12GB DDR3 Corsair Dominator -CMD12GX3M6A1600C8 at 1600MHz
Graphics Card(s)
Zotac Geforce GTX 770
Sound Card
ASUS Xonar D2X
Monitor(s) Displays
1 LG 24" Flatron W2453V-PF 1 Samsung 24" P2450H both 2ms RT
Screen Resolution
1920x1080@60hz
Hard Drives
1 Samsung 250GB 840 Evo SSD
1 OCZ Vertex2 180GB SSD
1 TB Samsung Spinpoint F1 7200RPM 32MB cache
2 500GB WD Caviar Blacks 7200RPM 32MB cache (WD5001AALS)

Pioneer DVD Burner DVR-S18M
PSU
Corsair HX1000W
Case
Cooler Master HAF 932
Cooling
Case Fans *3 230mm, *1 140mm/CPU - *Tuniq Tower 120 Extreme
Keyboard
Logitech Wireless MK700
Mouse
Logitech Wireless MK700
Internet Speed
DL 15 Mbps UL 0.98 Mbps
Antivirus
None
Browser
Firefox Nightly
Other Info
Processor-7.7 *RAM- 7.9 *Graphics-7.9 *Gaming Graphics- 7.9 *SSD- 7.8 W.E.I final score= 7.7
*Phone- LG Nexus 5
thanks, appreciate it. Though that doesn't have an idle option and it crashes on me.

If anybody has any other ideas please let me know...
 

My Computer My Computer

At a glance

Windows 7AMD Turion X2 RM-72 2.10 GHz Dual-Core Mobile...4GBATI Radeon HD 3200 Graphics RS780M
Computer Manufacturer/Model Number
Hewlett Packard dv4-1222nr
OS
Windows 7
CPU
AMD Turion X2 RM-72 2.10 GHz Dual-Core Mobile Processor
Memory
4GB
Graphics Card(s)
ATI Radeon HD 3200 Graphics RS780M
Monitor(s) Displays
14.1" LCD
Hard Drives
250GB (5400RPM)
Internet Speed
3.0 MBPS (down) / 1.0MBPS (up)
registry fix for you

this taken from How can I: Auto log user off after xx minutes? Shutdown.exe doesn't work with -l -t -c (why not!)

In order for non-administrators to be able to use WINEXIT, you must add Set Value and Create Subkey permissions for the group Everyone on the following registry key:
HKEY_Local_Machine\Software\Microsoft\Windows NT\CurrentVersion\IniFileMappings\Control.ini
To do this, use the following steps:

NOTE: You must be logged on with administrative rights to make these changes.

1. Start Registry Editor (Regedt32.exe).
2. Open the following key [by right-clicking control.ini]:
HKEY_Local_Machine\Software\Microsoft\Windows NT\CurrentVersion\IniFileMappings\Control.ini
3. click Permissions.
4. In the Name box, click or add Everyone, and then click the ADVANCED box for special permissions.
5. Click to select the Set Value and Create Subkey check boxes.
6. Click OK, and then click OK.
7. Quit Registry Editor, and then restart the computer.
http://support.microsoft.com/default.aspx/kb/156677


I have personally confirmed this to work on a windows 7 32bit htpc...lovin it :)
now to figure out how to change the message in the logoff box...
 

My Computer My Computer

At a glance

windows 7 32bitamd quad phenom x4 2.4g2gbradeon hd3870
Computer Manufacturer/Model Number
custom
OS
windows 7 32bit
CPU
amd quad phenom x4 2.4g
Motherboard
asus
Memory
2gb
Graphics Card(s)
radeon hd3870
Sound Card
onboard
Monitor(s) Displays
dual flat 19"
Hard Drives
250g ide
PSU
generic psu
Case
raidmax sagitta
Cooling
fans
Win7-64bit reg fix

Those instructions are not quite correct for Win7-64bit (Enterprise)
2. Open the following key [by right-clicking control.ini]:
HKEY_Local_Machine\Software\Microsoft\Windows NT\CurrentVersion\IniFileMappings\Control.ini

Here is the correct key for which you need to change permissions:
HKEY_Local_Machine\Software\Wow6432Node\Microsoft\Windows NT\CurrentVersion\IniFileMappings\Control.ini

The rest of the instructions are fine.

I've just done it, and it got rid of the the "Error encountered while creating registry key." problem.
 

My Computer My Computer

At a glance

Win7-64 Enterprise
OS
Win7-64 Enterprise
Autohost -- Thank you for that information. I made the change. However, the settings for the screensaver (force logoff, delay) do not save.

Is there a solution for that?

I wish MS would update their support docs for this.
 
Last edited:

My Computer My Computer

At a glance

Windows 7AMD Turion X2 RM-72 2.10 GHz Dual-Core Mobile...4GBATI Radeon HD 3200 Graphics RS780M
Computer Manufacturer/Model Number
Hewlett Packard dv4-1222nr
OS
Windows 7
CPU
AMD Turion X2 RM-72 2.10 GHz Dual-Core Mobile Processor
Memory
4GB
Graphics Card(s)
ATI Radeon HD 3200 Graphics RS780M
Monitor(s) Displays
14.1" LCD
Hard Drives
250GB (5400RPM)
Internet Speed
3.0 MBPS (down) / 1.0MBPS (up)
Strange, because they work for me. I did the permissions thing on the HKEY_Local_Machine\Software\Wow6432Node\Microsoft\Windows NT\CurrentVersion\IniFileMappings\Control.ini key, added EVERYONE to it, with the 2 special permissions. It saves changes just fine. Win7-64 Enterprise. I think I'm using the winexit.scr from the Win2003 Resource Kit, not the XP Resource Kit. They may be the exact same file though, I'm not sure.

 
Last edited:

My Computer My Computer

At a glance

Win7-64 Enterprise
OS
Win7-64 Enterprise
Just to point into a solution for inactive/idle logoffs (but more oriented towards businesses):
LogoffStandby
 

My Computer My Computer

At a glance

Mac OS X ;)
OS
Mac OS X ;)
Back
Top