riqrat Posted November 11, 2015 Share Posted November 11, 2015 I tried using one of the example scripts and it only works the first time I use it.Subsequent pressing of the Hotkey combination does nothing.Here is my script as is:#cs ---------------------------------------------------------------------------- AutoIt Version: 3.3.14.2 Author: myName Script Function: Template AutoIt script. #ce ---------------------------------------------------------------------------- ; Script Start - Add your code below here HotKeySet("{ESC}", "Terminate") HotKeySet("+z", "RunHurst") ;Shift-z While 1 Sleep(100) WEnd Func Terminate() Exit 0 EndFunc Func RunHurst() ShellExecute("G:\HURST\HURST.xltm","","","") EndFuncAfter I run this script, I can press Shift-Z and it will run my Excel file.After I'm done with the file and close it, but later press Shift-Z, nothing happens.Now, I'd rather just assign a Hotkey to run the script with just one line, the ShellExecute. But going into properties of the file does not have a Hotkey option so that is why I wrote the above. Any ideas?TIA Link to comment Share on other sites More sharing options...
Skysnake Posted November 11, 2015 Share Posted November 11, 2015 Not sure if this is your problem, but have a look at this:FAQ Why does the Ctrl key get stuck down after I run my script? Skysnake Why is the snake in the sky? Link to comment Share on other sites More sharing options...
AdmiralAlkex Posted November 12, 2015 Share Posted November 12, 2015 Now, I'd rather just assign a Hotkey to run the script with just one line, the ShellExecute. But going into properties of the file does not have a Hotkey option so that is why I wrote the above.Were you actually looking at a shortcut? Those are the only files that have that. .Some of my scripts: ShiftER, Codec-Control, Resolution switcher for HTC ShiftSome of my UDFs: SDL UDF, SetDefaultDllDirectories, Converting GDI+ Bitmap/Image to SDL Surface 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