candyman Posted April 9, 2009 Share Posted April 9, 2009 Hello, I am looking for a simple way to create a script to be converted to exe which works like this Compared to batch: wait.exe 120 //After the start 120 Seconds nothing happens Rundll32 user32.dll,LockWorkStation // Lock Users Screen so that he has to relogin (Ctrl+Alt+Del) Does anyone have ideas? Link to comment Share on other sites More sharing options...
JRowe Posted April 9, 2009 Share Posted April 9, 2009 Right click on desktop, select the screensaver tab, check the "Display Welcome Screen" box, and set "Wait" to be two minutes, then click ok. [center]However, like ninjas, cyber warriors operate in silence.AutoIt Chat Engine (+Chatbot) , Link Grammar for AutoIt , Simple Speech RecognitionArtificial Neural Networks UDF , Bayesian Networks UDF , Pattern Matching UDFTransparent PNG GUI Elements , Au3Irrlicht 2Advanced Mouse Events MonitorGrammar Database GeneratorTransitions & Tweening UDFPoker Hand Evaluator[/center] Link to comment Share on other sites More sharing options...
KaFu Posted April 9, 2009 Share Posted April 9, 2009 (edited) #include <Timers.au3> While 1 sleep(10) if _Timer_GetIdleTime() > 120 * 1000 then Run("RunDll32.exe user32.dll,LockWorkStation") WEnd Edit: Oh, I see... you don't want to check for activity, just log-off after 120 seconds... sleep(120*1000) Run("RunDll32.exe user32.dll,LockWorkStation") Edited April 9, 2009 by KaFu OS: Win10-22H2 - 64bit - German, AutoIt Version: 3.3.16.1, AutoIt Editor: SciTE, Website: https://funk.eu AMT - Auto-Movie-Thumbnailer (2022-Nov-26) BIC - Batch-Image-Cropper (2023-Apr-01) COP - Color Picker (2009-May-21) DCS - Dynamic Cursor Selector (2024-Feb-16) HMW - Hide my Windows (2018-Sep-16) HRC - HotKey Resolution Changer (2012-May-16) ICU - Icon Configuration Utility (2018-Sep-16) SMF - Search my Files (2023-Jun-03) - THE file info and duplicates search tool SSD - Set Sound Device (2017-Sep-16) Link to comment Share on other sites More sharing options...
Recommended Posts
Create an account or sign in to comment
You need to be a member in order to leave a comment
Create an account
Sign up for a new account in our community. It's easy!
Register a new accountSign in
Already have an account? Sign in here.
Sign In Now