Esse script executa o logoff do usuário caso tente efetuar o login fora do horário autorizado, o respectivo script encontra-se configurado para efetuar o logoff entre 12:00 e 13:30
Dim objShell Set objShell = WScript.CreateObject ("WScript.shell") saida = "12:00" retorno = "13:30" dim i i=1 Do While i = 1 if hr >= saida AND hr <= retorno Then CreateObject("WScript.Shell").Run "\\zeus\NETLOGON\miller.hta", 1, True wscript.sleep 5000 objShell.run "C:\Windows\System32\rundll32.exe user32.dll,LockWorkStation" end if hr = FormatDateTime(now, 4) wscript.sleep 1000 Loop