rosscolcoo Posted October 9, 2018 Share Posted October 9, 2018 Hey all, I'm unable to run a .bat file using actions in iCue. It's a simple script that asks you if "you are sure" you want to sleep the system. So in case I accidentally hit the button it just brings up a command prompt instead of sleeping the system accidentally. Halp! Link to comment Share on other sites More sharing options...
solarity Posted October 9, 2018 Share Posted October 9, 2018 Can you elaborate, are you talking about a macro? Link to comment Share on other sites More sharing options...
hastegag Posted October 9, 2018 Share Posted October 9, 2018 i seem to recall issues in the past with either powershell scripts or batch files getting embedded or hidden in shell host, but that may have only been powershell. Can you confirm your are on the latest icue i think it is 3.7.99? Link to comment Share on other sites More sharing options...
rosscolcoo Posted October 11, 2018 Author Share Posted October 11, 2018 Can you elaborate, are you talking about a macro? I'm clicking "Actions" then "Run the following program" then putting in the path to the .bat file. This does not work. It will not open any .bat file even though it clearly states "*.exe *.bat & *.cmd" as acceptable files to have. I am running the latest version. 3.7.99 Link to comment Share on other sites More sharing options...
rosscolcoo Posted October 11, 2018 Author Share Posted October 11, 2018 Also, after I sleep my computer, sometimes the device is not recognized and I have to unplug/replug in the keyboard.... VERY ANNOYING I hope there is a fix for this asap as well. Link to comment Share on other sites More sharing options...
hastegag Posted October 11, 2018 Share Posted October 11, 2018 hey rosso, you are correct sorry i thought this had been fixed. the bat file does not work at all in this icue version either and this has been happening since before. You can use the following workaround in the meantime although it is conviluded(sp?) and probable there is a better way: Add this to the launch application line for example: c:\users\username\desktop\acrun.exe "c:\users\username\desktop\test.cmd" I made this batch file and saved it to the desktop i made it a .cmd but it could be a bat if you like i think it would work even as a ps1 but have not tested (you might need to run powershell first in that case): @ECHO ON ECHO HELLO Timeout /t 3 EXIT I made this AHK file and compiled it once, or if you like you can download it at the link below and save to your desktop: #NoEnv ; Recommended for performance and compatibility with future AutoHotkey releases. SendMode Input SetWorkingDir %A_ScriptDir% ;"C:\Program Files\SketchUp\SketchUp 2018\SketchUp.exe" ;c:\Users\username\Desktop\acRun.ahk "C:\Program Files\SketchUp\SketchUp 2018\SketchUp.exe" fullPathToExecutable=%1% SplitPath, fullPathToExecutable, OutFileName, OutDir, OutExtension, OutNameNoExt, OutDrive IfWinNotExist, ahk_exe %OutFileName% run %fullPathToExecutable% ;MsgBox %OutFileName% IfWinExist ahk_exe %OutFileName% WinActivateBottom ahk_exe %OutFileName% return Exit you will need to install a recent version 1xx of Autohotkey if you do not use the exe. Link http://www.smithany.com/acRun.exe That worked for me anyways. As to the re plug necessity you might want to try the bios settings and make sure legacy is disabled? sometimes using usb 2 or 3 can make a difference for some or even sometimes updating the bios drivers (but that is a last resort) Link to comment Share on other sites More sharing options...
Recommended Posts