[Windows] 網域管理 / 自動登出逾時未操作的使用者
1.先下載 WINEXIT.rar,如果是2003用戶就不用了。
2.其實自動登出是靠 winexit.scr 這隻螢幕保護程式,將剛剛下載的檔案解壓縮到 C:\Windows\System32
3.控制台→顯示→螢幕保護程式→Logoff Screen Server→設定→勾選Force application termination(關閉應用程式的啦,若不勾應用程式不會關)
上述功能可以在單機上使用,若是配合Active Directory 的 Group Policy那管理起來更是方便了。
1.複製 winexit.scr 檔案到要設定的Client電腦中
2.program→run→gpedit.msc→user Configuration→Administrative Templates→Control Panel→Display
Screen Server:Enable
Sereen Server excurable name:%systemroot%\System32\winexit.scr
Password protect the screen saver:Enable
Screen Saver timer:Enable,視情況而定輸入時間。
3.將以下文字部份複製貼入記事本中,儲存名稱為 winexit.adm,編碼為 unicode;並將 winexit.adm 複製到 C:\Windows\inf
CLASS USER
CATEGORY !!AdditionalSettings
CATEGORY !!Desktop
CATEGORY !!WinExitScr
KEYNAME "Control Panel\Screen Saver.Logoff"
POLICY !!ForceLogoff
VALUENAME ForceLogoff
EXPLAIN !!ForceLogoff_Help
VALUEON "1"
VALUEOFF "0"
END POLICY
POLICY !!CountDownTimer
EXPLAIN !!CountDownTimer_Help
PART !!WarningTime TEXT END PART
PART " " NUMERIC TXTCONVERT REQUIRED
MIN 0 MAX 900 SPIN 60
VALUENAME CountDownTimer
DEFAULT "300"
END PART
END POLICY
POLICY !!DialogMessage
EXPLAIN !!DialogMessage_Help
PART !!Message TEXT END PART
PART " "
EDITTEXT
DEFAULT !!DefaultMessage
VALUENAME DialogMessage
END PART
END POLICY
END CATEGORY ; !!WinExitScr
END CATEGORY ; !!Desktop
END CATEGORY ; !!AdditionalSettings
[strings]
Desktop=Desktop
AdditionalSettings=Additional settings
WinExitScr=Settings for WinExit screen saver
ForceLogoff=Force running applications to close
ForceLogoff_Help="強制關閉開啟中的應用程式"
CountDownTimer=Warn before logoff
CountDownTimer_Help="登出執行視窗內的提醒時間(秒)"
WarningTime=Seconds to warn before logoff:
DialogMessage=Display message before logoff
DialogMessage_Help="登出執行視窗內的顯示訊息"
Message=Message:
DefaultMessage=You will be logged off. Press cancel to abort.
4.在Administrative Templates→Add/Remove Templates→Add→選擇winexit.adm
5.Fillering→取消 Only show policy setting that can be fully managed
6.Additional settings → Desktop → Settings for WinExit screen saver,自行設定 WinExit 的三個選項
設定 WinExit 的三個選項,原理就像下圖一樣。
若有謬誤,煩請告知,新手發帖請多包涵
Microsoft MVP Award 2010~2017 C# 第四季
Microsoft MVP Award 2018~2022 .NET