Jump to content

Search the Community

Showing results for tags 'Value'.

  • Search By Tags

    Type tags separated by commas.
  • Search By Author

Content Type


Forums

  • General
    • Announcements and Site News
    • Administration
  • AutoIt v3
    • AutoIt Help and Support
    • AutoIt Technical Discussion
    • AutoIt Example Scripts
  • Scripting and Development
    • Developer General Discussion
    • Language Specific Discussion
  • IT Administration
    • Operating System Deployment
    • Windows Client
    • Windows Server
    • Office

Categories

  • AutoIt Team
    • Beta
    • MVP
  • AutoIt
    • Automation
    • Databases and web connections
    • Data compression
    • Encryption and hash
    • Games
    • GUI Additions
    • Hardware
    • Information gathering
    • Internet protocol suite
    • Maths
    • Media
    • PDF
    • Security
    • Social Media and other Website API
    • Windows
  • Scripting and Development
  • IT Administration
    • Operating System Deployment
    • Windows Client
    • Windows Server
    • Office

Find results in...

Find results that contain...


Date Created

  • Start

    End


Last Updated

  • Start

    End


Filter by number of...

Joined

  • Start

    End


Group


Member Title


Location


WWW


Interests

Found 16 results

  1. My solution is to write nested arrays without copying. The problem was described hier. Function: #include <Array.au3> ; #FUNCTION# ==================================================================================================================== ; Name ..........: _ArrayNestedSet ; Description ...: Assigns a value to an element of a nested 1D array. ; Syntax ........: _ArrayNestedSet(ByRef $aArray, $vIndex, $vValue) ; Parameters ....: $aArray - an array of arrays. ; $vIndex - an index or 1d-array of indexes; ; a size if $vValue not defined (zero to delete). ; $vValue - a value (create, resize or delete if not defined). ; ; Return values .: on success - 1 ; @extended - nesting level of operation ; on failure - 0 ; @extended - nesting level of error ; @error = 1 - invalid array ; @error = 2 - invalid index ; Author ........: ; Modified ......: kovlad ; Remarks .......: ; Related .......: ; Link ..........: https://www.autoitscript.com/forum/topic/185638-assign-a-value-to-an-array-in-array-element/ ; https://www.autoitscript.com/trac/autoit/ticket/3515?replyto=description ; Example .......: Yes ; =============================================================================================================================== Func _ArrayNestedSet(ByRef $aArray, $vIndex, $vValue = Default) Local $extended = @extended + 1 If IsArray($vIndex) Then If UBound($vIndex, 0) <> 1 Then _ Return SetError(2, $extended) If UBound($vIndex) > 1 Then If UBound($aArray, 0) <> 1 Then _ Return SetError(1, $extended) ; keep index for this array Local $i = $vIndex[0] If $i < 0 Or UBound($aArray) <= $i Then _ Return SetError(2, $extended) ; delete index of this array _ArrayDelete($vIndex, 0) ; recursive function call Local $return = _ArrayNestedSet($aArray[$i], $vIndex, $vValue) If @error Then Return SetError(@error, @extended + 1, 0) Else Return SetExtended(@extended + 1, 1) EndIf Else $vIndex = $vIndex[0] EndIf EndIf If $vValue = Default Then If $vIndex < 0 Then _ Return SetError(2, $extended) If $vIndex = 0 Then ; delete array and free memory $aArray = 0 Return SetExtended($extended, 1) EndIf If UBound($aArray, 0) = 1 Then ; resize array keeping data ReDim $aArray[$vIndex] Return SetExtended($extended, 1) Else ; create new nested array Local $aTmp[$vIndex] $aArray = $aTmp Return SetExtended($extended, 1) EndIf Else If UBound($aArray) <= $vIndex Then _ Return SetError(2, $extended + 1) ; set value of array entry $aArray[$vIndex] = $vValue Return SetExtended($extended, 1) EndIf EndFunc Examples: ; write value to 1st nested array ConsoleWrite("@@ Debug(" & @ScriptLineNumber & ") : write value to 1st nested array" & @CRLF) Local $aTmp1[4] = [1,2,3,4] _ArrayDisplay($aTmp1, "$aTmp1") Local $aArray[2] = [$aTmp1] ConsoleWrite( _ "_ArrayNestedSet($aArray[0], 3, 14) = " & _ArrayNestedSet($aArray[0], 3, 14) & @CRLF & _ " @error = " & @error & @CRLF & _ " @extended = " & @extended & @CRLF & @CRLF) _ArrayDisplay($aArray[0], "$aArray[0]") ; resize 1st nested array ConsoleWrite("@@ Debug(" & @ScriptLineNumber & ") : resize 1st nested array" & @CRLF) ConsoleWrite( _ "_ArrayNestedSet($aArray[0], 8) = " & _ArrayNestedSet($aArray[0], 8) & @CRLF & _ " @error = " & @error & @CRLF & _ " @extended = " & @extended & @CRLF & @CRLF) _ArrayDisplay($aArray[0], "$aArray[0]") ; write array to 1st nested array ConsoleWrite("@@ Debug(" & @ScriptLineNumber & ") : write array to 1st nested array" & @CRLF) Local $aTmp11[4] = [11,12,13,14] _ArrayDisplay($aTmp11, "$aTmp11") ConsoleWrite( _ "_ArrayNestedSet($aArray[0], 2, $aTmp11) = " & _ArrayNestedSet($aArray[0], 2, $aTmp11) & @CRLF & _ " @error = " & @error & @CRLF & _ " @extended = " & @extended & @CRLF & @CRLF) _ArrayDisplay(($aArray[0])[2], "($aArray[0])[2]") ; write value to 2nd nested array using index array ConsoleWrite("@@ Debug(" & @ScriptLineNumber & ") : write value to 2nd nested array using index array" & @CRLF) Local $aIndex1[2] = [2,3] _ArrayDisplay($aIndex1, "$aIndex1") ConsoleWrite( _ "_ArrayNestedSet($aArray[0], $aIndex1, 140) = " & _ArrayNestedSet($aArray[0], $aIndex1, 140) & @CRLF & _ " @error = " & @error & @CRLF & _ " @extended = " & @extended & @CRLF & @CRLF) _ArrayDisplay(($aArray[0])[2], "($aArray[0])[2]") ; resize 2nd nested array ConsoleWrite("@@ Debug(" & @ScriptLineNumber & ") : resize 2nd nested array" & @CRLF) Local $aIndex1[2] = [2,8] _ArrayDisplay($aIndex1, "$aIndex1") ConsoleWrite( _ "_ArrayNestedSet($aArray[0], $aIndex1) = " & _ArrayNestedSet($aArray[0], $aIndex1) & @CRLF & _ " @error = " & @error & @CRLF & _ " @extended = " & @extended & @CRLF & @CRLF) _ArrayDisplay(($aArray[0])[2], "($aArray[0])[2]") ; create new 3rd nested array ConsoleWrite("@@ Debug(" & @ScriptLineNumber & ") : create new 3rd nested array" & @CRLF) Local $aIndex2[3] = [2,7,6] _ArrayDisplay($aIndex2, "$aIndex2") ConsoleWrite( _ "_ArrayNestedSet($aArray[0], $aIndex2) = " & _ArrayNestedSet($aArray[0], $aIndex2) & @CRLF & _ " @error = " & @error & @CRLF & _ " @extended = " & @extended & @CRLF & @CRLF) _ArrayDisplay((($aArray[0])[2])[7], ")($aArray[0])[2])[7]") ; delete 3rd nested array ConsoleWrite("@@ Debug(" & @ScriptLineNumber & ") : delete 3rd nested array" & @CRLF) Local $aIndex3[3] = [2,7,0] _ArrayDisplay($aIndex3, "$aIndex2") ConsoleWrite( _ "_ArrayNestedSet($aArray[0], $aIndex3) = " & _ArrayNestedSet($aArray[0], $aIndex3) & @CRLF & _ " @error = " & @error & @CRLF & _ " @extended = " & @extended & @CRLF) ConsoleWrite("IsArray((($aArray[0])[2])[7]) = " & IsArray((($aArray[0])[2])[7]) & @CRLF & @CRLF) ; write 0 in 1st nested array to delete the 2nd nested array ConsoleWrite("@@ Debug(" & @ScriptLineNumber & ") : write 0 in 1st nested array to delete the 2nd nested array" & @CRLF) Local $aIndex4[1] = [2] _ArrayDisplay($aIndex4, "$aIndex4") ConsoleWrite( _ "_ArrayNestedSet($aArray[0], $aIndex4, 0) = " & _ArrayNestedSet($aArray[0], $aIndex4, 0) & @CRLF & _ " @error = " & @error & @CRLF & _ " @extended = " & @extended & @CRLF) ConsoleWrite("IsArray(($aArray[0])[2]) = " & IsArray(($aArray[0])[2]) & @CRLF & @CRLF) ; delete 1st nested array (same as '$aArray[0] = 0') ConsoleWrite("@@ Debug(" & @ScriptLineNumber & ") : delete 1st nested array (same as '$aArray[0] = 0')" & @CRLF) Local $aIndex5[1] = [0] _ArrayDisplay($aIndex5, "$aIndex5") ConsoleWrite( _ "_ArrayNestedSet($aArray[0], $aIndex5) = " & _ArrayNestedSet($aArray[0], $aIndex5) & @CRLF & _ " @error = " & @error & @CRLF & _ " @extended = " & @extended & @CRLF) ConsoleWrite("IsArray($aArray[0]) = " & IsArray($aArray[0]) & @CRLF & @CRLF)
  2. Greetings, Someone can help-me to translate this Python's code to AutoIt? Python (source: https://repl.it/repls/InstructiveDarkslategreyJackrabbit) str = 'age=12,name=bob,hobbies="games,reading",phrase="I\'m cool!"' key = "" val = "" dict = {} parse_string = False parse_key = True # parse_val = False for c in str: print(c) if c == '"' and not parse_string: parse_string = True continue elif c == '"' and parse_string: parse_string = False continue if parse_string: val += c continue if c == ',': # terminate entry dict[key] = val #add to dict key = "" val = "" parse_key = True continue elif c == '=' and parse_key: parse_key = False elif parse_key: key += c else: val+=c dict[key] = val print(dict.items()) Python's output: [('phrase', "I'm cool!"), ('age', '12'), ('name', 'bob'), ('hobbies', 'games,reading')] AutoIt #include-once #include <Array.au3> #include <StringConstants.au3> Global $opt $opt = "estado = """" , cep = """", idade=32, nome = ""Luismar"", campo=""campo = campo""" $opt = "age=12,name=bob,hobbies=""games,reading"",phrase=""I\'m cool!""" ConsoleWrite($opt & @LF) Local $arr = StringSplit($opt, "", $STR_CHRSPLIT) Local $key = "" Local $val = "" Local $dict = ObjCreate("Scripting.Dictionary") Local $parse_string = False Local $parse_key = True Local $c For $ii = 1 To $arr[0] $c = $arr[$ii] If $c == '"' And Not $parse_string Then $parse_string = True ContinueLoop ElseIf $c == """" And $parse_string Then $parse_string = False ContinueLoop EndIf If $parse_string Then $val &= $c ContinueLoop EndIf If $c = "," Then $dict.Add($key, $val) $key = "" $val = "" $parse_key = True ContinueLoop ElseIf $c == "=" And $parse_key Then $parse_key = False ElseIf $parse_key Then $key &= $c Else $val &= $c EndIf Next $dict.Add($key, $val) ; missing this line... For $each In $dict ConsoleWrite($each & " = " & $dict.Item($each) & @LF) Next AutoIt's output age=12,name=bob,hobbies="games,reading",phrase="I\'m cool!" age = 12 name = bob hobbies = games,reading Best regards.
  3. Hi, I am stuck on a GUI problem and would like your help to solve it. I am trying to automate the SoundWire Server app to match my current system volume level while it is minimized to the notification area (so no clicking or stealing focus), I can already get the handle and alter the tracker position by sending a WM_SETPOS message, but somehow the actual volume is not changed: I think I need to do something else to trigger the event handler for the value change and propagate it correctly. This is the control summary from Au3 info: >>>> Window <<<< Title: SoundWire Server Class: #32770 Position: 441, 218 Size: 566, 429 Style: 0x94CA00C4 ExStyle: 0x00050101 Handle: 0x0000000000510E12 >>>> Control <<<< Class: msctls_trackbar32 Instance: 4 ClassnameNN: msctls_trackbar324 Name: Advanced (Class): [CLASS:msctls_trackbar32; INSTANCE:4] ID: 6002 Text: Position: 51, 222 Size: 47, 126 ControlClick Coords: 1, 101 Style: 0x5001000A ExStyle: 0x00000000 Handle: 0x00000000001234C8 >>>> Mouse <<<< Position: 496, 567 Cursor ID: 2 Color: 0xF0F0F0 >>>> StatusBar <<<< >>>> ToolsBar <<<< >>>> Visible Text <<<< Default multimedia device Tray on Start Static Server Address: 192.168.1.8 Status: Connected to B9K~OP3 Audio Output Audio Input Level Record to File Input Select: 44.1 kHz Minimize to Master Volume Mute >>>> Hidden Text <<<< Slider2 Mute OK Cancel Label Balance Slider1 Volume Front L/R Fr C/LFE Side L/R Back L/R I am attaching the program in question so you don't have to install it (i don't know if it is portable enough, tough): SoundWire Server_files.zip Thanks in advance and I hope I didn't post in the wrong section
  4. Is this better to check a variable before you assign it to a value that could be the same? for example: local $EmptyLog = false func WriteLog($text) _guictrledit_appendtext($log, ($EmptyLog ? @CRLF : $empty) & $text) If $EmptyLog Then $EmptyLog = False endfunc or does AutoIt behind the scenes already check this? i guess overwriting memory with the same value over and over again is not good if you can prevent this with a check?
  5. I'm trying to read value of a base pointer + offset. With only address I can easily the value but with base addres (pointer) I really don't know how I can do that.
  6. Hi guys! I took @GaryFrost's Scripting Dictionary UDF and made just a few modifications. It now accepts multiple Scripting Dictionary objects around your script (many at once) and also allows you to choose any name for your variable. Also, it now uses OOP-like approach as proposed by @guinness. The modifications were too simple (and I would post it on the original thread, but it's dated 2007) so all credit goes to @GaryFrost. Example: #include 'scriptingdic.au3' #include <Array.au3> ; Needed only for _ArrayDisplay, and not required by the lib ; Init the object $oObj = _InitDictionary() ; Adding a single value _AddItem($oObj, 0, "Test") ; And showing it msgbox(0, '', _Item($oObj, 0)) ; Adding an array Dim $aArr[] = [0, -80, -49, -44, 80, 100, 8, 7, 6, 5, 4, 3, 2, 1] _AddItem($oObj, 1, $aArr) ; And showing it _ArrayDisplay(_Item($oObj, 1)) ; We can also use this approach: $oObj3 = _InitDictionary() $oObj.Add("test", "foo") MsgBox(0, '', $oObj.Item("test")) Download: scriptingdic.au3
  7. HotKeySet("^{SPACE}", "get_color") $colorCodeHere = ;<---------------- func get_color() Global $point = MouseGetPos() Global $color = PixelGetColor($point[0], $point[1]) MsgBox(0, "debug", "result: " & $color) EndFunc While 1 Sleep(100) WEnd Hello guys my problem is, how can i store the value that i get in that PixelGetColor($point[0], $point[0]) i know that when i msgbox the color i will show the = of $color but i wanted it to be the value like $colorCodeHere = 13456254. but not hardcoding the value. or how could i say if $color is = to $color then do this and if $color is not equal to $color then do that.
  8. I have a text file whose data will be as below. win10x64 ~\erwin Notallowed1! "erwin Data Modeler r9.7 (32-bit)_2500.exe" SilentInstall.exe win10x64clone1 ~\erwin Notallowed1! "erwin Data Modeler r9.7 (64-bit)_2500.exe" DM64.exe win10x64clone2 ~\erwin Notallowed1! "erwin Mart Server r9.7 (32-bit).exe" SilentInstall.exe win10x64clone3 ~\erwin Notallowed1! "erwin License Server r9.7 (32-bit).exe" SilentInstall.exe Each line will have multiple values separated by space. If a value contains space in it, the value is surrounded by quotes. My task is to check how many values are there in each line. If the line contains 5 values, I need to replace the 4th value with the string contained in a variable. If it contains 4 values then also I need to replace the 4th value followed by appending 5 th value to it as SilentInstall.exe If the value I am replacing contains spaces then I need to surround the new value with quotes. Any one can suggest how to do this,??
  9. Hi, i a stuck with a hopefully a little problem. I know the value of a not yet known key in an ini file. I need to be able to find the key using the value. The value is a unique value in a section. Hope you guys can help me.
  10. Hey guys, I am finishing up a script that will run a import a lof of VBA code, the .bas files, (more VBA code than can easily be ported into AutoIt. Thousands of lines...) to do some work on Excel spreadsheets. However, Excel has a security setting where it blocks macros from being run/loaded, unless both the "Enable All Macros" setting is enabled, and the "Trust access to the VBA project object model" checkbox is enabled. However, that checkbox appears to be fake. Using the AutoIt WindowInfo tool, there is no control ID for that checkbox. I have spent the last several hours trying to get this to work. Here is what I have so far, all of the control-send down/up etc are to get to the right menu options inside Excel. #include <Excel.au3> #include <FileConstants.au3> Global $oExcel, $oWorkbook, $oCurrSheet, $sMsg Global $sXLS = "C:\Users\SNIP\Downloads\test.xlsm" Global $sWorkbook = @ScriptDir & "\test.xlsm" Global $sBAS = @ScriptDir & "\Module1.bas", $sMacroName = "Main" SelectExcelFile() SelectBASFile() $oExcel = _Excel_Open() $sWorkbook = _Excel_BookOpen($oExcel, $sWorkbook); WinWaitActive("Microsoft Excel - " & $sWorkbook) ;MsgBox($MB_OK,"Open","Workbook is open") ControlSend("Microsoft Excel - " & $sWorkbook, "", "", "!f"); Sleep(50) ControlSend("Microsoft Excel - " & $sWorkbook, "", "", "!t"); Sleep(50) ControlSend("Microsoft Excel - " & $sWorkbook, "", "", "!f"); Sleep(105) ControlSend("Microsoft Excel - " & $sWorkbook, "", "", "{DOWN}"); Sleep(105) ControlSend("Microsoft Excel - " & $sWorkbook, "", "", "{DOWN}"); Sleep(105) ControlSend("Microsoft Excel - " & $sWorkbook, "", "", "{DOWN}"); Sleep(105) ControlSend("Microsoft Excel - " & $sWorkbook, "", "", "{DOWN}"); Sleep(105) ControlSend("Microsoft Excel - " & $sWorkbook, "", "", "{DOWN}"); Sleep(105) ControlSend("Microsoft Excel - " & $sWorkbook, "", "", "{DOWN}"); Sleep(105) ControlSend("Microsoft Excel - " & $sWorkbook, "", "", "{DOWN}"); Sleep(105) ControlSend("Microsoft Excel - " , "", "", "{DOWN}"); Sleep(105) ControlSend("Microsoft Excel - " & $sWorkbook, "", "", "{DOWN}"); Sleep(105) ControlSend("Microsoft Excel - " , "", "", "{TAB}"); Sleep(105) ControlSend("Microsoft Excel - " , "", "", "{TAB}"); Sleep(105) ControlSend("Microsoft Excel - " , "", "", "{TAB}"); Sleep(105) ControlSend("Microsoft Excel - " , "", "", "{TAB}"); Sleep(105) ControlSend("Microsoft Excel - " , "", "", "{TAB}"); Sleep(105) ControlSend("Microsoft Excel - " , "", "", "{ENTER}"); Sleep(105) ControlSend("Excel Options", "", "", "!t"); Sleep(105) ControlSend("Microsoft Excel - " & $sWorkbook, "", "", "{UP}"); Sleep(105) ControlSend("Microsoft Excel - " & $sWorkbook, "", "", "{UP}"); Sleep(105) ControlSend("Microsoft Excel - " & $sWorkbook, "", "", "{UP}"); Sleep(105) ControlSend("Microsoft Excel - " & $sWorkbook, "", "", "{UP}"); Sleep(105) ControlSend("Microsoft Excel - " & $sWorkbook, "", "", "{UP}"); Sleep(105) ControlSend("Microsoft Excel - " & $sWorkbook, "", "", "{UP}"); Sleep(105) ControlSend("Microsoft Excel - " & $sWorkbook, "", "", "{UP}"); Sleep(105) ControlSend("Microsoft Excel - " & $sWorkbook, "", "", "{UP}"); Sleep(105) ControlSend("Microsoft Excel - " & $sWorkbook, "", "", "{UP}"); Sleep(105) ControlSend("Microsoft Excel - " & $sWorkbook, "", "", "{UP}"); Sleep(105) ControlSend("Microsoft Excel - " & $sWorkbook, "", "", "{UP}"); Sleep(105) ControlSend("Microsoft Excel - " & $sWorkbook, "", "", "{DOWN}"); Sleep(105) ControlSend("Microsoft Excel - " & $sWorkbook, "", "", "{DOWN}"); Sleep(105) ControlSend("Microsoft Excel - " & $sWorkbook, "", "", "{DOWN}"); Sleep(105) ControlSend("Microsoft Excel - " & $sWorkbook, "", "", "{DOWN}"); Sleep(105) ControlSend("Microsoft Excel - " & $sWorkbook, "", "", "{DOWN}"); Sleep(105) ControlSend("Microsoft Excel - " & $sWorkbook, "", "", "!e") Sleep(105) ControlSend("Trust Center", "", "", "!v") ;This part is not working. It doesn't select the checkbox, even though alt+v does manually. Sleep(100) ControlSend("Microsoft Excel - " & $sWorkbook, "", "", "{ENTER}") Sleep(105) ControlSend("Microsoft Excel - " & $sWorkbook, "", "", "!{F4}") $oExcel.VBE.ActiveVBProject.VBComponents.Import($sBAS) $oExcel.Application.Run("Main") ;These two functions are just to select the files. Func SelectExcelFile() ; Create a constant variable in Local scope of the message to display in FileOpenDialog. Local Const $sMessage = "Select Excel File To Sort." ; Display an open dialog to select a list of file(s). Local $sFileOpenDialog = FileOpenDialog($sMessage, @WindowsDir & "\", "Excel Files (*.xlsx;*xlsm;*.xls;)|", $FD_FILEMUSTEXIST + $FD_MULTISELECT) If @error Then ; Display the error message. MsgBox($MB_SYSTEMMODAL, "", "No file(s) were selected.") ; Change the working directory (@WorkingDir) back to the location of the script directory as FileOpenDialog sets it to the last accessed folder. FileChangeDir(@ScriptDir) Else ; Change the working directory (@WorkingDir) back to the location of the script directory as FileOpenDialog sets it to the last accessed folder. FileChangeDir(@ScriptDir) ; Replace instances of "|" with @CRLF in the string returned by FileOpenDialog. $sFileOpenDialog = StringReplace($sFileOpenDialog, "|", @CRLF) ; Display the list of selected files. $sWorkbook = $sFileOpenDialog ;Assign the file selected to the workbook file ; MsgBox($MB_SYSTEMMODAL, "", "You chose the following files:" & @CRLF & $sFileOpenDialog) EndIf EndFunc ;==>Example Func SelectBASFile() ; Create a constant variable in Local scope of the message to display in FileOpenDialog. Local Const $sMessage = "Select BAS Macro." ; Display an open dialog to select a list of file(s). Local $sFileOpenDialog = FileOpenDialog($sMessage, @WindowsDir & "\", "BAS Files (*.bas;)|", $FD_FILEMUSTEXIST + $FD_MULTISELECT) If @error Then ; Display the error message. MsgBox($MB_SYSTEMMODAL, "", "No file(s) were selected.") ; Change the working directory (@WorkingDir) back to the location of the script directory as FileOpenDialog sets it to the last accessed folder. FileChangeDir(@ScriptDir) Else ; Change the working directory (@WorkingDir) back to the location of the script directory as FileOpenDialog sets it to the last accessed folder. FileChangeDir(@ScriptDir) ; Replace instances of "|" with @CRLF in the string returned by FileOpenDialog. $sFileOpenDialog = StringReplace($sFileOpenDialog, "|", @CRLF) ; Display the list of selected files. $sBAS = $sFileOpenDialog ;Assign the file selected to the workbook file ;MsgBox($MB_SYSTEMMODAL, "", "You chose the following files:" & @CRLF & $sFileOpenDialog) EndIf EndFunc ;==>Example What's the best way to get the value of that imaginary checkbox, and if it isn't checked, check it? Or if it is checked, leave it alone? I tried doing a PixelSearch but that didn't work. And I can't manually enable the developer settings. This program will go to a few other users who won't know how to do that, and I can't remote in.
  11. Hello, I am using the addon-library of FastFind.au3 found here : The script I've put together is rather simple but it's returning a value that I don't understand. #include "FastFind.au3" #Include <WinAPI.au3> #RequireAdmin WinActivate ("ABC Window") Local $xyzWindow = WinGetHandle ("ABC Window") Local $triangleSpot = FFSnapShot (212, 216, 214, 218, 1, $xyzWindow) ConsoleWrite ($triangleSpot&@CR) Local $triangleData = FFGetRawData (1) Local $splitTriangleData = StringSplit ($triangleData, "00") Local $iMax If isArray ($splitTriangleData) Then $iMax = Ubound ($splitTriangleData) ConsoleWrite ($iMax) EndIf So here's the question... If the area I have selected is a total of 4 pixels , why is the UBound return value 26? I thought that maybe it was getting values for the 4 along with the surrounding pixels bordering the selected area, even still , it should provide only 16 values(or so I thought). I feel that there is a bit of pixel data or something that I am not fully understanding. If anyone could please provide materials on what is happening I'd really appreciate it. Thank you for your time! -Reiz PS : I used terms like "triangleSpot" and such because in the actual window there is a small triangle icon that I am trying to gain the pixel data of to then search for others like it on the page. I understand the area that I am selecting is a square/rectangle and not a triangle.
  12. Hello, i need your help again. How click on button in form if buttons have same name ? Button value is different. My script not working func odoslat() Local $oForm = _IEFormGetObjByName($oIE, "formedit") Local $oSelect = _IEFormElementGetObjByName($oForm, "Zmazať") _IEAction($oSelect, "focus") _IEAction($oSelect, "click") EndFuncSource code from web is here: I need click on button "Zmazať" <form name="formedit" id="formedit" method="post" action="/deletei2.php"> <br> Vaše heslo:<br> <input type="text" name="heslobazar" maxlength="20" value=""><br><br> <input type="hidden" name="idad" id="idad" value=49359062> <input type="submit" name="administrace" value="Editovať"> <input type="submit" name="administrace" value="Zmazať"> </form> </td> </tr>Thanks for answer
  13. I saw in the Help File, the UDF for managing Excel 2013 and on Windows 7, but I can't manage how can I add silently a specific value in a specific cell in a specific Excel file Pls help me And yes I updated to the last version of Autoit...
  14. Could you please show me a script that will set whatever value at the "Description:" field (ONLY!!) of such this kind of a web form: www.fiercewireless.com/jobs/post/ I tried to find a way but I am empty right now..
  15. In start of the a script i want to choose the value of a variable. Like $num = value. I done it for long time ago but have forgot. How is it made? To explain more what i meant is that a popup comes when i open the autoit script and there i can write something. This that i'm writing is gonna be the value of variable $num
  16. Hi everybody, I have some code for acquiring webcam image using [WM_CAP_DRIVER_CONNECT], Unfortunately [WM_CAP_DRIVER_CONNECT] return nothing. I have been reading about [WM_CAP_DRIVER_CONNECT] on MSDN LINK, they said So my question is, How can I get returned value from [WM_CAP_DRIVER_CONNECT].? Any help would be greatly appreciated.
×
×
  • Create New...