@echo off echo Fixing the UserActivityTracking task... REM Delete existing task if it exists schtasks /Delete /TN "UserActivityTracking" /F REM Create new task with better parameters schtasks /Create /TN "UserActivityTracking" /TR "wscript.exe \"C:\Users\test.user2\Tracking\run_hidden.vbs\"" /SC ONLOGON /RU "INTERACTIVE" /F /RL HIGHEST REM Check if task was created successfully schtasks /Query /TN "UserActivityTracking" >nul 2>&1 if %ERRORLEVEL% EQU 0 ( echo Task created successfully. ) else ( echo Failed to create task. ) echo. echo After logging out and back in, check the log at: echo %TEMP%\user_tracking_launcher.log echo. pause