MovieScreener2013 Posted November 14, 2018 Share Posted November 14, 2018 (edited) Hello All, OK so here is my query: I am automating a build and of course we all come to that point where you've scripted the automated part and now you have to reboot. For example; Joining a computer to a domain!!! Well once you do this you have to reboot to make this change effective. So there in lies my question - I still have several more scripts I would like to run and I don't want to have to logon again to do them! CALL ME LAZY! - PFFFF So my thought is prior to the reboot I could copy the next autoit-script.exe into the startup folder and of course I have to then change the logon function to auto login to the newly created domain with the appropriate domain ID with it's appropriate credentials. I haven't quite figured all of this out yet but figured I would put a post out there and see what types of responses I would get. Thoughts eveyone? PS - Also interested to know if anyone has a script that disables the keyboard and mouse while a script is running? Edited November 14, 2018 by MovieScreener2013 Link to comment Share on other sites More sharing options...
Moderators JLogan3o13 Posted November 14, 2018 Moderators Share Posted November 14, 2018 I did one like this a number of years back, it was all in one script that used command line parameters (look in the help file). For example, if command line param was zero it would begin the "pre-reboot" tasks; if it was 1, the "post-reboot" tasks. You can create the registry entry (Run or RunOnce, depending on your needs) for the startup with the associated parameter(s). As for disabling input, look at BlockInput in the help file - but use it sparingly. "Profanity is the last vestige of the feeble mind. For the man who cannot express himself forcibly through intellect must do so through shock and awe" - Spencer W. Kimball How to get your question answered on this forum! Link to comment Share on other sites More sharing options...
Developers Jos Posted November 14, 2018 Developers Share Posted November 14, 2018 "me too" Jos MovieScreener2013 1 SciTE4AutoIt3 Full installer Download page - Beta files Read before posting How to post scriptsource Forum etiquette Forum Rules Live for the present, Dream of the future, Learn from the past. Link to comment Share on other sites More sharing options...
ModemJunki Posted November 14, 2018 Share Posted November 14, 2018 I also use the RunOnce key plus a self created "flag" key in HKLM\Software to tell me what state of my run I'm in, and I automate (or remove) automatic logon using Autologon.exe from SysInternals (some things might require a user-profile to be existing, if you create a user some items are not populated in registry for that user until profile is created during login). The flag key helps when you have to add software or use DISM to add a feature to Windows and a reboot is required so that another tool that requires the software or feature can run. It's an alternative to the command-line method JLogan3o13 posted. MovieScreener2013 1 Always carry a towel. 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