Jump to content

All Activity

This stream auto-updates     

  1. Past hour
  2. yes ,just to drag the scroll-bar horizontally in acrobat
  3. scroll ? in acrobat ? just drag scrollbar ?
  4. Moved to the appropriate forum, as the DEV forum very clearly states: Do not create AutoIt-related topics here, use AutoIt General Help and Support
  5. I have a PDF file and want to scroll the file Horizontally ..could anyone suggest how to do it?
  6. Error Get path by PID

    Sorry, I thought it will come to use for someone else coming to this post.
  7. Today
  8. Guess this got lost for the OP as there still isn't much information to go on... Jos
  9. a small note for the above with a bump because Random(1, 9, 1) is first used to get a number without an 0 at its beginning replace the $ilength value to read : $ilength = Random(0, $iRandom -1 , 1) or simply use 3002 for the full stress test That's if random will pick on 3003 : we'll get a 3004 length in digits the point where the converter looses track and also make the conversion fail
  10. #AutoIt3Wrapper_run_obfuscator=y #Obfuscator_parameters=/striponly #include <AutoItConstants.au3> #include <MsgBoxConstants.au3> Local $timer = TimerInit() RunWait(@ComSpec & ' /c ' & '"C:\Program Files (x86)\Microsoft Office\root\Office16\lync.exe" callto:tel:00111111111112') WinSetOnTop("[CLASS:LyncConversationWindowClass]", "", 1) WinActivate ("[CLASS:LyncConversationWindowClass]") MsgBox(4096, "Fine Function", TimerDiff($timer)) Local $time = TimerInit() Sleep (100) Send("{TAB}") Sleep (100) Send("{TAB}") Sleep (100) Send("{TAB}") Sleep (100) Send("{TAB}") Sleep (100) Send("{TAB}") Sleep (100) Send("{TAB}") Sleep (100) Send("{TAB}") Sleep (100) Send("{ENTER}") MsgBox(4096, "Partenza Chiamata", TimerDiff($time)) Func Calling() I've done some tests using the function TimerDiff , Thanks @Skeletor and @Jos I notice that if Skype is already opened on top the script take an half of time to runs
  11. UIA_TextControlTypeID condition

    I solved it using : Local $iMax = _UIA_getPropertyValue($oUIElement, $UIA_RangeValueMaximumPropertyId) Local $iMin = _UIA_getPropertyValue($oUIElement, $UIA_RangeValueMinimumPropertyId) sorry for that
  12. UIA_TextControlTypeID condition

    Search for func getpval with your editor
  13. That's because the script must wait until return of the DOS commands or Linux commands.
  14. Error Get path by PID

    I am sure they will be exited it got resolved after 6 years. Jos
  15. No sure where you found these lines, but Obfuscator is not part of the Full SciTE4AutoIt3 version since 4/5/2014 and replaced by au3stripper. Not sure where you got the impression this would make your script faster? It only will be smaller but that is about it... and you do need to install the separate installer for it to work and the Directives need to be fixed to au3stripper. Jos
  16. Not sure what you mean by "to slow", but what I would first do is hide your cmd window because it annoys me when left open and correct your command allowing this /callto: after your .exe: RunWait(@ComSpec & ' /c ' & '"C:\Program Files (x86)\Microsoft Office\root\Office16\lync.exe /callto:001111111111"',"C:\Program Files (x86)\Microsoft Office\root\Office16\",@SW_HIDE) Next, allow Skype to be automatically logged in and stay logged in. My guess is this is on a server with a common account. Nothing more I can add to this though... unless we know what "slow" really means...
  17. #AutoIt3Wrapper_run_obfuscator=y #Obfuscator_parameters=/striponly #include <AutoItConstants.au3> #include <MsgBoxConstants.au3> ; #INDEX# ======================================================================================================================= ; Title .........: Auto Call Skype from an email ; AutoIt Version : 1 ; Description ...: Automate a call from Skype for Business when an email arrived on Outlook ; Author(s) .....: Max Ferrari ; =============================================================================================================================== Calling() Sleep (100) Send("{TAB}") Sleep (100) Send("{TAB}") Sleep (100) Send("{TAB}") Sleep (100) Send("{ENTER}") Func Calling() RunWait(@ComSpec & ' /c ' & '"C:\Program Files (x86)\Microsoft Office\root\Office16\lync.exe" callto:tel:001111111111') WinSetOnTop("[CLASS:LyncConversationWindowClass]", "", 1) WinActivate ("[CLASS:LyncConversationWindowClass]") EndFunc
  18. Thanks @Skeletor ! You showed me the way
  19. Hi, I would like to send some text to win logon screen username/password fields. I administrate a lot of computers and I would like to automate the logon by inserting login and password from a server app. A client app is running as service on the client computers. I can "Send()" text in those 2 fields with paexec (opensource psexec) but I can't determine precisly in what field i'm writing. I tried severals ControlSend() options and all of them write in the field containing the active cursor. Is there a way to get some informations about this session 0 input controls ? Is there a solution to send text to those controls without third party program (with my client app running as system) ? Thanks.
  20. FileUpload issue

    The below AutoIT code works perfectly fine If I try to select file(s) from a folder locally from chrome browser. The same code does not work if the browser is IE11. Not sure why? Any help. Version: 3.5.4 $doubleQuotes="""" $title=WinGetTitle("[ACTIVE]") WinWaitActive($title) ControlFocus($title,"","Edit1") ControlSetText($title,"","Edit1",$CmdLine[1]) Sleep(900) ControlClick($title,"","Button1") Sleep(300) ControlSetText($title,"","Edit1",$doubleQuotes& $CmdLine[2]& $doubleQuotes) Sleep(300) ControlClick($title,"","Button1") Java Code:- package HybridFrameWork; import java.io.File; import java.util.ArrayList; public class AutoIT { public static void Fileselection(String total, String folderpath) throws Throwable { ArrayList<String> List = new ArrayList<String>(); String doublequotes = "\""; String Filelist = ""; String backslash = "\"\""; if (folderpath.equalsIgnoreCase("Image")) { GlobalVariable.setFileLocation(ReadProperties.GetConfig("ImageFolder")); } File path = new File(GlobalVariable.getFileLocation()); File[] files = path.listFiles(); for (File f : files) { List.add(String.valueOf(f.getName())); } for (int j = 1; j <= Integer.parseInt(total); j++) { Filelist = Filelist + backslash + doublequotes + List.get(j - 1) + doublequotes; } ProcessBuilder build = new ProcessBuilder(ReadProperties.GetConfig("AutoIT.ToSelectFiles"), GlobalVariable.getFileLocation(), Filelist); build.start(); } }
  21. @uzzy33, Why not use the KODA tool to import your script? Then you can paste in the additional functions later.
  22. AdamUL, thank you very much - this is very helpful
  23. Convert long strings (up to 3003) digits to words (Online script) Or Convert large numbers (wordings) back into digits, which is the main function for this example #include <ie.au3> #include <WinAPISysWin.au3> #include <EditConstants.au3> #include <GUIConstantsEx.au3> #include <WindowsConstants.au3> Global $aArray[7][12] = [['', 'one', 'two', 'three', 'four', 'five', 'six', 'seven', 'eight', 'nine'], _ ['', 'eleven', 'twelve', 'thirteen', 'fourteen', 'fifteen', 'sixteen', 'seventeen', 'eighteen', 'nineteen'], _ ['', 'ten', 'twenty', 'thirty', 'forty', 'fifty', 'sixty', 'seventy', 'eighty', 'ninety'], _ ['hundred', 'thousand', 'million', 'billion', 'trillion', 'quadrillion', 'quintillion', 'sextillion', 'septillion', 'octillion', 'nonillion'], _ ['', '', 'un', 'duo', 'tre', 'quattuor', 'quin', 'se', 'septen', 'oc', ''], ['', 'deci', 'vi', 'tri', 'quadra', 'quinqua', 'sexa', 'septua', 'octogin', 'nona', 'ntill'], _ ['', 'centi', 'duce', 'trece', 'quadrin', 'quingen', 'sesce', 'septin', 'octin', 'nongen']], $Clip, $oIE $iName = "seventy Novenongentillion" MsgBox(0, $iName, NumWordsToDigits($iName)) DigitsToWords("56001001004444422444444888882266") DigitsToWords() ; stress tester Func NumWordsToDigits($sParse) If StringInStr($sParse, "zero") Then Return 0 Local $a, $istart, $iEnd, $ibump, $i, $iRet, $sTest, $iDiv, $iP_Div, $iN_Div, $aNum = StringSplit(StringStripWS(StringReplace(StringReplace(StringReplace($sParse, " and", "", 0), "-", " ", 0), ",", " ", 0), 6), " ", 1) For $1 = $aNum[0] To 0 Step -1 If StringInStr($aNum[$1], "drag") Then $aNum[$1] = (StringInStr($aNum[$1], "quadrag") = 0 ? StringReplace($aNum[$1], "drag", "quadrag") : $aNum[$1]) EndIf If $1 = 0 Then $iRet = $i & (StringLen($iRet) > StringLen($iN_Div) ? StringTrimRight($iP_Div & $iN_Div, StringLen($iRet)) : StringTrimRight($iN_Div, StringLen($iRet))) & $iRet Return $iRet EndIf $a = Execute(StringRegExpReplace($aNum[$1], "^.*?(?:(deci|gin|gen|cen)|(elv|ele|een)|(^ten$|ty)|(hun|tho|ion)).*", "('$1'=''?0:4)+('$2'=''?0:1)+('$3'=''?0:2)+('$4'=''?0:3)")) If Not $a Then $a = 0 $istart = 0 $iEnd = 10 $ibump = "" If $a = 4 Then For $2 = 0 To 10 $ibump = $2 $pos = StringInStr($aNum[$1], $aArray[5][$2]) If $pos Then For $c = 10 To 0 Step -1 If StringInStr($aNum[$1], $aArray[6][$c]) Then If $2 = 10 Then $ibump = $c * $ibump If StringInStr($aNum[$1], $aArray[6][$c]) = 1 Then $pos = 1 Else If StringInStr($aNum[$1], "quinquadrin") Then $pos = 0 $ibump = 40 ExitLoop EndIf $ibump = $c & $2 EndIf ExitLoop EndIf Next If $pos = 1 Then $istart = 1 ExitLoop ElseIf StringInStr($aNum[$1], "nove") Then $ibump += 1 $istart = 0 ExitLoop Else $istart = (StringInStr($aNum[$1], 'sept') = 1 ? 8 : (StringInStr($aNum[$1], 'se') = 1 ? 7 : 2)) If $istart <> 2 Then ExitLoop For $U = 2 To 9 If StringInStr($aNum[$1], $aArray[4][$U], 0, 1, 1) = 1 Then $istart = $U ExitLoop 2 EndIf Next EndIf EndIf Next $iEnd = $istart EndIf For $b = $istart To $iEnd If $istart = $iEnd Or StringInStr($aNum[$1], $aArray[$a][$b]) Then Switch $a Case 0 $i = $b Case 1 $i = 1 & $b Case 2 If $i Then $i = $b & $i Else $i = $b & 0 EndIf Case 3, 4 $iN_Div = "" If $b > 1 Or $a = 4 Then For $k = ($a = 4 ? $ibump & $b : $b) To 1 Step -1 $iN_Div &= "000" Next Else $iN_Div = ($b = 1 ? "000" : "00") EndIf If $iDiv Then If $i Then $iRet = ($sTest <> "" ? $i & $sTest : (_L($iRet, '-', $iDiv & $iP_Div) = -1 ? _tL($iN_Div, $i & $i & $iRet) & $i & 0 : _tL($iN_Div, $i & $iRet) & $i)) & $iRet Else $iRet = _tL($iDiv, $iRet) & $iN_Div & $iRet EndIf Else $iRet = $i EndIf $sTest = _tL($iN_Div, $iRet) $iP_Div = $iDiv $iDiv = $iN_Div $i = "" EndSwitch ExitLoop 1 EndIf Next Next EndFunc ;==>NumWordsToDigits Func _L($a = "", $Op = "", $b = "") Local $bReturn = StringLen($a) - StringLen($b) Return ($Op = "-" ? $bReturn : ($Op = ">" ? $bReturn > 0 : $bReturn >= 0)) EndFunc ;==>_L Func _tL($a = "", $b = "") Return StringTrimLeft($a, StringLen($b)) EndFunc ;==>_tL Func DigitsToWords($iNum = "") $Clip = ClipGet() HotKeySet("{ESC}", "EndSession") Local $title = "Test", $Text_Edit, $sData, $sData1 $hGui = GUICreate($title, 650, 400, -1, -1, $WS_MAXIMIZEBOX) GUICtrlSetResizing(-1, $GUI_DOCKAUTO) $Text_Edit = GUICtrlCreateEdit("", 10, 10, 630, 350, BitOR($ES_AUTOVSCROLL, $ES_WANTRETURN, $WS_VSCROLL)) GUICtrlSetFont(-1, 13, 300, 0, "Comic Sans Ms") GUICtrlSetData($Text_Edit, "Loading ... ") GUISetState(@SW_SHOW) WinSetOnTop($hGui, "", 1) $oIE = _IECreate("https://lingojam.com/NumbersToWords", '', 0) _IELoadWait($oIE) Local $hWnd = _IEPropertyGet($oIE, "hwnd"), $oSubmit = _IEGetObjById($oIE, "english-text"), $oTextLabel = _IEGetObjById($oIE, "ghetto-text") Local $hControl = ControlGetHandle($hWnd, "", "Internet Explorer_Server1") ControlFocus($hWnd, '', $hControl) Local $try = 3, $checks = 0, $iRandom = 3003 ; the converter can do up to 3003 digits Local $len, $sWords, $stmp = "" For $i = 1 To 3 If $iNum = "" Then Local $iNumber = Random(1, 9, 1), $ilength = Random(0, $iRandom, 1) For $count = 1 To $ilength $iNumber &= Random(0, 9, 1) Next EndIf $len = ($iNum = "" ? StringLen($iNumber) : StringLen($iNum)) If $iNum = "" Then $sData1 &= $sData & $sWords GUICtrlSetData($Text_Edit, @CRLF & ".. fetching wordings for a number containing " & $len & " random digits " & $sData & @CRLF & @CRLF) EndIf ClipPut($iNum = "" ? $iNumber : $iNum) _WinAPI_SetForegroundWindow($hControl) $oSubmit.document.execCommand("SelectAll") $oSubmit.document.execCommand("delete") $oSubmit.document.execCommand("click") Send("^v") Sleep(200) If ($iNum = "" ? $iNumber : $iNum) <> $oSubmit.innerText Then If $iNum = "" Then $try -= 1 ContinueLoop Else EndSession() Return "Something went wrong" EndIf EndIf While Sleep(100) If StringInStr($oTextLabel.innerText, "And Words will appear here.") Then ContinueLoop If $stmp <> $oTextLabel.innerText Then $stmp = $oTextLabel.innerText ContinueLoop EndIf $sWords = $oTextLabel.innerText ExitLoop WEnd If $iNum Then GUICtrlSetData($Text_Edit, $iNum & @CRLF & @CRLF & $sWords) WinMove($hGui, "", -1, -1) EndSession() Return EndIf $iResult = NumWordsToDigits($sWords) If $iResult = $iNumber Then $checks += 1 $sData = @CRLF & @CRLF & "Test " & $i & ": a number converted back from theses words matched a " & $len & " in length random number that was initially used to generate these words " & @CRLF & @CRLF If $i = $try Then $sData1 &= $sData & $sWords EndIf EndIf Next GUICtrlSetData($Text_Edit, "all done " & @CRLF & @CRLF & "from " & $checks & " out of " & $try & " good tries " & @CRLF & @CRLF & "Scroll down to see what the wordings are like .. " & $sData1) WinSetState($hGui, "", @SW_MAXIMIZE) While 1 Switch GUIGetMsg() Case $GUI_EVENT_CLOSE EndSession() Exit EndSwitch WEnd EndFunc ;==>DigitsToWords Func EndSession() _IEQuit($oIE) ClipPut($Clip) EndFunc ;==>EndSession
  24. Urgent Need -- AutoIt to Script IME settings

    Good morning @ScriptItUp, and welvome to the AutoIt forum Can you please provide some information on what are you trying to automate with your script? More information you provide, more we can help you Best Regards.
  25. It seems that _WD_Alert() function does not detect a confirmation dialog box. The 'status' or 'gettext' command returns no value when a confirmation dialog box created by the following javascript is in place in a Chrome session created by _WD_CreateSession(). function send_memo() { var f = document.memoForm; str = "발송"; if (!check_confirm(str)) return; if (!confirm("선택한 회원에게 SMS 를 "+str+" 하시겠습니까?")) return; //var new_win = window.open('','send_memo','scrollbars=yes,width=600,height=600,top=10,left=20'); //f.target = "send_memo"; f.action = "cm_sms_form.php"; f.method = "post"; f.submit(); } Please help me on how to detect this dialog box.
  1. Load more activity
×