8 posts in this topic
Good morning AutoIt community!
Today, I'm here to ask you if you know how to run an .exe from cmd.exe ( Command Prompt )...
My intention is to read a .ini file where I store an information that has to be included in the shell, and run an .exe with that information...
I'll give you an example
Local $aFileCartellaAuditCopy = _FileListToArray($sPercorsoAuditCopy, "*.txt") If @error Then MsgBox($MB_ICONERROR, "Errore!", "Errore durante la lettura della lista dei file nella directory" & @CRLF & $sPercorsoAuditCopy & @CRLF & "Errore: " & @error) Return False Else Local $iPID = Run("cmd.exe" & ' /k "C:\Users\Portatile-60\Desktop\HmiCheckLogIntegrity.exe" "C:\Users\Portatile-60\Desktop\AuditTrailDosaggio0_20170327_151335_DOSAGGIO_PW_01.txt"') ; & " /k " & '"' & $sHmiCheckLogIntegrity & '"' & " " & '"' & $sPercorsoAuditCopy & "\" & $aFileCartellaAuditCopy & '"', "", @SW_SHOW, $STDOUT_CHILD) Return True EndIf This code is in a function, that returns False if it can retrive at least a file from the path stored in the .ini file...
I would like to run the Command Prompt with the .exe and with a parameter of that .exe, but it seems to not work properly.
Could please anyone tell me why?
I'm stuck with this regular expression, for matching a iso standard version
what I want to do is match the text in green: ISO 11784:1996/Amd.2:2010(E)
there is also others that look like this: ISO 11789:1999(E), and without the (E) part,
Só I did this one
(?i)ISO.+?[\d-]+:(?:\d+/Amd.+?:)?[\d-]+(?:\(\w\))* to match both cases but doesn't ignore the text in red
Can somebody point out what I'm doing wrong here?
I am trying to do something a little whacky but here's the function that's kicking back an error.
I am fairly sure I am overlooking a simple error but I am not seeing it.
Func mouseSpot () Global $mouseSpot = MouseGetPos() ConsoleWrite ($mouseSpot & ", " & $mouseSpot & @CRLF) FileWriteLine ("mouseGrabs.txt" , "MouseClick ('"'primary'"' , $mouseSpot , $mouseSpot, 1, 10)" ) EndFunc The error displays as this
I'm getting the syntax error: "Statement cannot be just an expression."
Here's the piece of code where it occurs:
$Check = WinExists("MySQL Installer") If $Check <> "" Then WinClose("MySQL Installer") Else $Check = ControlGetHandle("", "&No", '[CLASS:Button; INSTANCE:2]') If $Check <> "" Then ControlClick("", "&No", '[CLASS:Button; INSTANCE:2]') Sleep(10000) WinClose("MySQL Installer") EndIf EndIf Anyone know why this error is occurring?