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


  1. Posts : 63
    Windows 7
       #1

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


    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


  2. Posts : 18,404
    Windows 7 Ultimate x64 SP1
       #2
      My Computer


  3. Posts : 63
    Windows 7
    Thread Starter
       #3

    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


  4. Posts : 5
    windows 7 32bit
       #4

    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


  5. Posts : 2
    Win7-64 Enterprise
       #5

    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


  6. Posts : 63
    Windows 7
    Thread Starter
       #6

    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 by dockster; 15 Jul 2010 at 12:52.
      My Computer


  7. Posts : 2
    Win7-64 Enterprise
       #7

    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 by autohost; 19 Jul 2010 at 14:08.
      My Computer


  8. Posts : 1
    Mac OS X ;)
       #8

    Just to point into a solution for inactive/idle logoffs (but more oriented towards businesses):
    LogoffStandby
      My Computer


 

  Related Discussions
Our Sites
Site Links
About Us
Windows 7 Forums is an independent web site and has not been authorized, sponsored, or otherwise approved by Microsoft Corporation. "Windows 7" and related materials are trademarks of Microsoft Corp.

© Designer Media Ltd
All times are GMT -5. The time now is 20:26.
Find Us