I wrote a script that will log someone out of the ticketing system I use at my company, is it possible to create a script to check if the user has been idle for about 5 minutes (i.e, no keystrokes or mouse movement) one they're idle initiate the script I wrote to log them out. Once they're logged out the script would need to be restarted. But since there won't constantly be someone on submitting a ticket can you also make so it only reactivates the idle timer once someone initiates another keystroke/mouse movement?
This is my script:
@echo off
Taskkill /im firefox.exe
CD C:\Users\username\AppData\Roaming\Mozilla\Firefox\Profiles\profilename
del *"cookies.sqlite"*
CD C:\Program Files (x86)\Mozilla Firefox
start firefox.exe http://sysaid.sdairy.com/Login.jsp
Set WshShell = WScript.CreateObject("WScript.Shell")
WshShell.AppActivate("Mozilla Firefox")
WshShell.SendKeys "{ALT}", "{TAB}"
(This just closes the browser, deletes the cookies then restarts the browser in the webpage I need and alt tabs to make sure that the browser window is in front of the desktop).
Let me know if you need more information please! Thank you in advance.