Leaderboard
Popular Content
Showing content with the highest reputation on 11/13/2020 in all areas
-
@Nine Just noticed I haven't used shuffle before, and had to look for it. It does have shuffle (all my music is offline in VLC). That icon looked like a cross-fade to me It does add existing songs in a playlist if they reside in different albums though (same name, different album), feature for some, bug for others perhaps.2 points
-
Automate all windows and browser applications with one UDF function library. Based on the microsoft automation API this library high level supports Recognition of conttrols from EDGE, Chrome, FF, Opera, Safari and Windows native apps Small testing framework to split object repository from coding away Introduction Quickstart - Getting started quickly Simple scripts With this module you can automate all applications/programs that support ui automation and/or accesibility api from microsoft you can recognize more controls than AutoIT can recognize "out of the box" you can use concepts from other testing frameworks like http://download.freedesktop.org/ldtp/doc/ldtp-tutorial.pdf http://safsdev.sourceforge.net/Default.htm coded ui testing from microsoft Some of those controls / applications are chrome browser (partly mainwindow has to be done with MSAA for navigating) chrome://accessibility in the adress bar of chrome or start with "--force-renderer-accessibility" silverlight controls Ribbon control controlbars of Excel/Word IE and FF browsers Windows Media Player Windows clock AFX .. controls (partly) .... Based on the initial AIO Object I now have made the interface file to work with objCreateInterface function which is in the latest beta's automate clicking and querying basic information It gives you a lot of basic information to be able to automate clicking, querying basic information where it goes further in certain situations than AutoIt is identifying Starting threads for background on the ui automation api of microsoft (not for starters) http://en.wikipedia.org/wiki/Microsoft_UI_Automation http://msdn.microsoft.com/en-us/library/ms747327.aspx Previous threads in general help/support Interface AutoItObject IUIAutomation ObjCreateInterface and struct tagPoint in method ElementFromPoint Be aware that API is not allways installed under XP/Vista see http://support.microsoft.com/kb/971513 Within Windows 7 and Windows 8 it should be preinstalled by default. Be aware on 32 and 64 bits way of running your script #AutoIt3Wrapper_UseX64=Y or N Basic example of usage / showing and retrieving the default information, will post multiple examples later Hover your mouse to an area of interest and press ctrl+w and information will be shown in the edit box of the form Simple spy demo (see simplespy.au3 or use latest ZIP attachment for latest version) Main features Recognize windows and html controls for the major browsers Logical and physical description for controls (UI mapping, Application map) Simple repository logic to abstract logical and physical descriptions Store Runtime Type Information in RTI. variables Rubberbanding/highlighting of objects Simple spy to help in making / identifying the physical description Support of regular expression(s) in identifying objects recognize objects on multiple properties supported properties: name ,title, automationid, classname, class, iaccessiblevalue, iaccessiblechildId, controltype, processid, acceleratorkey The actions provided so far "leftclick", "left", "click", "leftdoubleclick", "leftdouble", "doubleclick", _ "rightclick", "right", "rightdoubleclick", "rightdouble", _ "middleclick", "middle", "middledoubleclick", "middledouble", "mousemove", "movemouse" "setvalue","settextvalue" "setvalue using keys" "setValue using clipboard" "getvalue" "sendkeys", "enterstring", "type", "typetext" "invoke" "focus", "setfocus", "activate" "close" "move","setposition" "resize" "minimize", "maximize", "normal", "close", "exist", "exists" "searchcontext", "context" "highlight" "getobject","object" "attach" "capture","screenshot", "takescreenshot" "dump", "dumpthemall" "propertyvalue", "property" match on multiple properties like: name:=((Zoeken.*)|(Find.*)); ControlType:=Button; acceleratorkey:=Ctrl+F Support for 117 different properties see $UIA_propertiesSupportedArray in uiawrappers like for example title, regexptitle, class, regexpclass, iaccessiblevalue, iaccessiblechildid, name, accesskey, automationid, classname IAccessible, IAccessible2, ISimpleDom interfaces debuglogging to a file log.txt (no output in scitewindow) Examples Example 1 Iterating thru the different ways of representing the objects in the tree (#comment-1105548) Example 2 Finding the taskbar and clicking on the start menu button (#comment-1105680) Example 3 Clicking a litlle more and in the end displaying all items from the clock (thats not directly possible with AU3Info) (#comment-1108849) Example 4 that demonstrates the calculator Example 5 Automating chrome Example 6 Demonstrates all stuff within chrome to navigate html pages, find hyperlink, click hyperlink, find picture, click picture, enter data in inputbox Example 7 The chrome example modified to a firefox example Example 8 The other major browser Internet Explorer automated (made on Example 6 and 7) Example 9 Windows media player Example 10 Automating mach 3 (AFX windows and other hard to get recognized by AutoIT) Lot of links are broken due to forum upgrade just search for the text like "Example 11 Demonstrate Word, Notepad and Calculator actions" Example 11 Demonstrate Word, Notepad and Calculator actions ... Example 13 Details 1 about the right pane of the windows explorer Example 14 Details 2 about the right pane of the windows explorer Example 15 Details 3 about the right pane of the windows explorer Example 16 Details 4 about the right pane of the windows explorer Example 17 Details 5 about the right pane of the windows explorer WITH CACHING Example 18 Details 6 about the right pane of the windows explorer WITH VIRTUAL ITEMS Example 19 Eventhandling examples Example 20 Eventhandling examples Example 21a Eventhandling examples Internet Explorer Example 21b Eventhandling examples Internet Explorer Example 22 Eventhandling examples Follow focus Example 23 Eventhandling examples structure changed Example 24 Eventhandling examples IUIAutomationEventHandler Example 25 SAFEARRAYS Example 26 IACCESSIBLE / MSAA Example 27 IACCESSIBLE2 / MSAA Example 28 IACCESSIBLE / MSAA events Example 29 IACCESSIBLE2 events Example 30 ISimpleDOM Example 31 Notepad window move, maximize, minimize Example 32 Three browsers doing the same stuff with small differences in scripting only .. TODO Build recorder Enhance the spy with a nicer UI UI for the repository (now in the script with dot notation) Enhance mapping / identifying on multiple properties instead of 1 combined with index If speed becomes an issue use the caching logic of the MS UIA framework Add the other patterns later Generalize the concept of System Under Test of starting the SUT (for testing framework purposes) Remote running of scripts Fix issue on finding within dynamic context ... edit august 18th 2013 initial post Only zip files are needed to download , just unzip in 1 directory edit july 2016 Made V0_63 and examples works with AutoIt v3.3.14 Windows 10 tested Simple spy gives some basic code as a present Chrome latest versions seems to be having issues with IUIAutomation on tabs/buttons of mainwindow use MSAA for accessing tabsheets / buttons more cleanup to be in UDF style More comments in the source see changelog.txt for previous changes edit september 2017 All examples fixed for the IE, Firefox and Chrome browser Some small but essential fixes in UIAWrappers edit april 2018 Enhanced logic on fallback / dynamic search, still not perfect, to slow Retested with latest Chrome, FF, Edge and IE11 and some extensions to show how to get text from the webpage (examples 5,6,7) Some small bugfixes Some comments as given in forum incorporated edit may 2019 Speed enhancements on especially fallback searching UIA.CFG works now in a better way to turn on/off debug, highlighting, debug2file More stable and consistent behavior Internal cleanup and refactoring of bigger functions Checked with W10 (not tested on W7) Added some W10 properties Run with 3.3.14.5 on W10 UIA_V0_51.zip EXAMPLES_V0_5.zip UIA_V0_63.zip EXAMPLES_V0_63.zip UIA_V0_64.zip EXAMPLES_V0_64.zip EXAMPLES_V0_66.zip UIA_V0_66.zip EXAMPLES_V0_70.zip UIA_V0_70.zip1 point
-
27 November 2019: Uploaded a new SciTe4AutoIt3.exe v19.1127.1402.0 installer. This version contains the new SciTE 4.2.0 version. Check below for all other updates to the included utilities. ==> SciTE4AutoIt3 v19.1127.1402.0 Enjoy, Jos Addition/Changes/Fixes in the current installer: -------------------------------------------------------------------------------------------------- 27-11-2019 *** Merged the SciTE v 4.2.0 by Neil Hodgson with our own version of SciTE. (Jos) *** Updated AutoIt3Wrapper v19.1127.1402.0 (Jos) - 19.102.1901.1 added encoding retrieval for UTF8/ANSI files so they are properly written back - 19.102.1901.2 Exit script with 999 when update resource copy failed . - 19.102.1901.3 Fix incrementing version number now before running au3stripper to ensure it contains the new version when increment before is requested. - 19.102.1901.4 increment version before au3stripper when increment before is Y - 19.102.1901.5 also update fileversion info in case of a3x compile when requested. - 19.102.1901.7 change au3check and tidy stop on error logic to allow for other editor programs. - 19.102.1901.8-11 Changes to allow the program to be run by other editors. - 19.102.1901.12 Updates Stop and Restartconsole message to indicate in case the HotKeys aren't set in case of second instance HotKeys are ony set when the Editor program has the focus to allow for multiple instances. - 19.102.1901.13 Updated _RefreshSystemTray, which wasn't working anymore since a long time - 19.102.1901.14 Added WinClose for the Shelled Script to nicely close that process before ultimately killing it when still needed. *** Updated Au3Stripper v19.1127.1402.0 (Jos) - 19.102.1901.2 Fixed not removing #pragma lines from Included files. - 19.102.1901.5 Fixed ternary stripping issue *** Updated SciTEConfig v19.1127.1402.0 (Jos) - 19.524.1057.1 Fixed creation of includes.txt in userdir and added some extra logging for adding includes to includes.txt - Some small updates to standard themes. *** Updated Tidy v19.1127.1402.0 (Jos) - 19.524.1057.1: Fix tidy issue adding space after closing > on #include statement. -------------------------------------------------------------------------------------------------- ==> ScitillaHistory page containing all SciTE-Scintilla updates. ==> Visit the SciTE4AutoIt3 Download page for the latest versions ==> Check the online documentation for an overview of all extra's you get with this installer.1 point
-
Sort arrow in _ArrayDisplay ?
mikell reacted to pixelsearch for a topic
Found the issue Original ArrayDisplayInternals.au3 (version 3.3.14.5) lines #560 to #563 : If Not IsHWnd($hWnd) Then $hWnd = GUICtrlGetHandle($hWnd) ;~ Local Const $LVM_GETHEADER = (0x1000 + 31) ; 0x101F Local $hHeader = HWnd(GUICtrlSendMsg($hWnd, 0x101F, 0, 0)) Move line #560 just below the 2 others : ;~ Local Const $LVM_GETHEADER = (0x1000 + 31) ; 0x101F Local $hHeader = HWnd(GUICtrlSendMsg($hWnd, 0x101F, 0, 0)) If Not IsHWnd($hWnd) Then $hWnd = GUICtrlGetHandle($hWnd) Now the sort arrow will be displayed when you sort on any column1 point -
Sort arrow in _ArrayDisplay ?
Zedna reacted to pixelsearch for a topic
Thanks guys for the test, which confirms the same behavior on all computers. This lack of the sort arrow is probably annoying for many users because this little arrow shows at same time which column is sorted + if the sort is ascending or descending. For example have a look at this link where paulpmeier had to describe what he was doing in his initial pics ("first click", "second click") because the sort arrow didn't show in _ArrayDisplay I found a couple of links, here and there (both from 2009) which lead us to the right direction, not counting the help file, topic _GUICtrlListView_SortItems (1st example) which shows it's possible to easily display a sort arrow when left clicking on the header column of a listview control. So the question is : why doesn't it work in _ArrayDisplay ? Melba23 could certainly answer to this question better than me, but meanwhile I'd like to share some thoughts with you. This is what we read at line #555 in ArrayDisplayInternals.au3 (version 3.3.14.5) ; #DUPLICATED Functions to avoid big #include <GuiListView.au3># ================================================================ ; Functions have been simplified (unicode inprocess) according to __ArrayDisplay_Share() needs Now let's have a look at 2 concerned lines in ArrayDisplayInternals.au3 1) Line #448 __ArrayDisplay_RegisterSortCallBack($idListView, 2, True, "__ArrayDisplay_SortCallBack") Let's replace it with its corresponding "original" line : _GUICtrlListView_RegisterSortCallBack($idListView, 2, True) 2) Line #522 __ArrayDisplay_SortItems($idListView, GUICtrlGetState($idListView)) Let's replace it with its original line : _GUICtrlListView_SortItems($idListView, GUICtrlGetState($idListView)) 3) And of course, for this test, let's add at the beginning of ArrayDisplayInternals.au3 : #include <GuiListView.au3> Now the sort arrow appears when you run the little test script posted above and you should have a display corresponding to the image in 1st post So it seems that there is a little "discrepancy" (?) between the #DUPLICATED Functions and the originals, which prevent the sort arrow to be displayed. As these functions are very similar, it shouldn't be too hard to compare both of them and finally allow everybody to display this important sort arrow in _ArrayDisplay, without including GuiListView.au3... of course1 point -
@CYCho Make sense. FWIW, they can co-exist but you would need to override the default port for one of them.1 point
-
Read File
JockoDundee reacted to GokAy for a topic
Hey all, @TheDcoder No, I didn't forget to put in $iLine, it was merely for displaying line number for console output. Should have mentioned that though @Jos I had to go out, so could only test it now. So @error is set afterwards, and it is ok. However, I noticed another mistake in YuChan's code. FileOpen with mode 1 (append mode) does not read any lines in my test. Default 0 works (as mentioned in FileReadLine details). Global $journalFile = FileOpen(@ScriptDir & "\dofbotJournal.txt") ; don't use mode 11 point -
1 point
-
I'm not sure that I completely understand your existing code, but this is what it would look like if I were to rewrite it -- If @OSArch = "x64" Then DllCall("kernel32.dll", "boolean", "Wow64DisableWow64FsRedirection", "boolean", 1) ;~ Turns On 64 Bit Redirection EndIf Local $hWnd = WinGetHandle("[CLASS:OSKMainClass]") If @error Then ShellExecute("osk.exe") WinWait("[CLASS:OSKMainClass]", 5) $hWnd = WinGetHandle("[CLASS:OSKMainClass]") ; This is what you were missing EndIf WinMove($hWnd, "", 563, 387, 1000, 400)1 point
-
SSH and cmd send password
faustf reacted to JLogan3o13 for a topic
Well, spoon-feeding it to you is what you usually want. I guess you can hope someone comes along that is willing to do the work for you after 9 years on the forum....1 point -
add this line after child creation : _WinAPI_RedrawWindow($h_GUI)1 point
-
Hi Paul, Long explanation coming Your comments can be explained, because _ArrayDisplay always uses a comparison type based on Windows API StrCmpLogical, as you can see in the help file, topic _GUICtrlListView_RegisterSortCallBack, where the 2nd parameter (= 2) means "Use Windows API StrCmpLogical" This corresponds to line #448 in ArrayDisplayInternals.au3 (version 3.3.14.5) __ArrayDisplay_RegisterSortCallBack($idListView, 2, True, "__ArrayDisplay_SortCallBack") When this 2nd parameter = 2, then the sort isn't done in a pure alphabetically (ascii) way because "Digits in the strings are considered as numerical content rather than text", as explained on the MSDN web page. A note from Wikipedia concerning this "natural sort" : Natural sort order is an ordering of strings in alphabetical order, except that multi-digit numbers are treated atomically, i.e., as if they were a single character. Natural sort order has been promoted as being more human-friendly ("natural") than the machine-oriented pure alphabetical order. It could explain why, in your very last diagram, when the 1st character in col1 is a digit (0 for all rows), then "01" means 1, "02" => 2, "03" => 3, while "0A" and "0B" equal to 0 (because their 1st 0 is not followed by a digit), which could explain why "0A" and "0B" are placed on the 1st two lines, in an ascending sort using StrCmpLogical Your other column (col0) doesn't have the same character at 1st place but a simple "1", "2", "3", "A", "B" In this case, I guess that StrCmpLogical immediately sorts the letters after the numbers when the sort is ascending, after comparing for example "3" to "A" and finding that the ascii code for "A" is higher than the ascii code for "3", which will result in an ascending sort like this : 1 - 2 - 3 - A - B So it seems that both columns have their contents treated very differently, depending on the fact that a digit is found or not... at least this is the only explanation I can find. If anyone could confirm or disprove this explanation, please do not hesitate, thanks I find it hard to solve your issue, because changing permanently the 2nd parameter in line #448 (from 2 to 0, meaning you want a pure String comparison) will solve your case... but will bring issues when you have numerals to compare. Same if you change it permanently from 2 to 1 ("String treated as number") The only (bad) way I found to sort correctly your pointers & handles (or any hex number starting with 0x) in your 1st diagram is : * Line 448 : 2nd parameter = 1 (String treated as number) * Lines 596 to 600, added a test on "0x" : If $__g_aArrayDisplay_SortInfo[8] = 1 Then ; force Treat as Number if possible If StringIsFloat($sVal1) Or StringIsInt($sVal1) Or StringLeft($sVal1, 2) = "0x" Then $sVal1 = Number($sVal1) If StringIsFloat($sVal2) Or StringIsInt($sVal2) Or StringLeft($sVal2, 2) = "0x" Then $sVal2 = Number($sVal2) EndIf Then an array like this one... Global $aSortTest[6][1] = [["0x0B"], ["0x020"], ["0x0C"], ["0x03"], ["0x01"], ["0x0A"]] ...would correctly be sorted (ascending) This is the reason why, in my CSV file editor, a choice is given to the user, before each sort (by right-clicking a header column) so the user chooses the kind of sort he wants, instead of being stuck with a "forced" way of sorting : This required of course to register the sort, do the sort, then unregister it each time the user wants to sort, no big deal. So, if this is really important to you, I guess you'll have to tweak a bit your own version of ArrayDisplayInternals.au3 Good luck1 point
-
Here's an example (based on nested Maps) you can play with. The function vd() produces a variable dump as the output shows. Local $m[] ; $m is a Map $m["abc"] = "This" $m["def"] = "That" $m["key"] = 111 vd($m) ; till now, everything was added explicitely ; now use a function to insert new value(s) to possibly already existing keys _Add2Map($m, "ghi", "One more value") ; key not existing vd($m) ; several values to existing key _Add2Map($m, "key", 123) _Add2Map($m, "key", 456) _Add2Map($m, "key", 789) vd($m) ; same value to existing key _Add2Map($m, "key", 456) vd($m) Func _Add2Map(ByRef $map, $key, $value) If MapExists($map, $key) Then ; same as If $m[$key] = Null Then If IsMap($map[$key]) Then MapAppend($map[$key], $value) Else Local $m2[] ; an empty map $m2[1] = $map[$key] $m2[2] = $value $map[$key] = $m2 EndIf Else $map[$key] = $value EndIf EndFunc Map[3] ['abc'] => String (4) 'This' ['def'] => String (4) 'That' ['key'] => Int32 111 Map[4] ['abc'] => String (4) 'This' ['def'] => String (4) 'That' ['key'] => Int32 111 ['ghi'] => String (14) 'One more value' Map[4] ['abc'] => String (4) 'This' ['def'] => String (4) 'That' ['key'] => Map[4] [1] => Int32 111 [2] => Int32 123 [3] => Int32 456 [4] => Int32 789 ['ghi'] => String (14) 'One more value' Map[4] ['abc'] => String (4) 'This' ['def'] => String (4) 'That' ['key'] => Map[5] [1] => Int32 111 [2] => Int32 123 [3] => Int32 456 [4] => Int32 789 [5] => Int32 456 ['ghi'] => String (14) 'One more value' Now I don't really get what/when you'll need to remove elements and on which criterion. Anyway, the keys of nested maps in this example are positive increasing integers in insert order. Removing any entry in a Map is faster than removing a row in an array.1 point
-
Version 1.15.4
863 downloads
cDebug.au3 includes four main debugging UDFs: _GuiDebug(), _ConsDebug(), _ClipDebug() and _FormatValsForDebug(). They all dump the values of all AutoIt subtypes and expressions, in a structured manner, including nested arrays (up to 3 dimensions) and slices of them, and even DLL structs and maps. It is an alternative to a graphical debugger, offering GUI output. The format for calling the UDFs has been designed to make coding a call as convenient and fast as possible, minimizing coding effort and the chances of errors: the $name argument is often the same as the variables arguments, enclosed in quote marks. For DLL structures, if you specify a tag, cDebug checks for differences between it and what it detects. If you only specify a structure variable, it can report the structure it detects, with the values of elements. It does much more than MsgBox(), ConsoleWrite() and _ArrayDisplay(), in a definitely user-friendly manner, and does its best to avoid hiding your code in SciTE. #include cDebug no maps.au3 or cDebug.au3 at the top of your script. If you #include cDebug.au3 (the version with maps) #include #AutoIt3Wrapper_Version=B before #include cDebug.au3 It is fully documented in . During debugging and development of new features, the current version is used to debug the upcoming version, so there is much testing, even so bugs are always possible, particularly in new features, such as reporting elements of maps whose keys match a regular expression. Bug reports and suggestions are welcome. These UDFs have been in regular use for some years. Because when cDebug was developed, maps were a use at your own risk feature, there are two streams of cDebug: cDebug.au3 reports maps, so to use it you must be running a version of AutoIt that supports maps, e.g. 3.3.15.0, and #include cDebug.au3 cDebug no maps.au3 does not report maps, so you can be running any recent version of AutoIt, e.g. 3.3.14.5, and #include cDebug no maps.au3 The only difference between the two streams is that map-reporting code is commented out in cDebug no maps.au3 . These functions are documented in cDebug.pdf A teaser This script: #AutoIt3Wrapper_Version=B ; beta 3.3.15.0 or greater is mandatory for cDebug.au3 #include "cDebug.au3" Local $seasons[] $seasons.summer = 'May to September' $seasons.spring = 'April' $seasons.fall = 'October to November' $seasons.winter = 'December to March' Local $aCats[3][3] = [['jack','black',3],['suki','grey',4],[$seasons,'','']] Local $i = 1 Local $tStruct = DllStructCreate('uint') DllStructSetData($tStruct,1,2018) _GuiDebug('At line '&@ScriptLineNumber,'$cats,jack is,$cats[..][$i],$i,hex,structure{uint}', _ $aCats,$aCats[0][2],$aCats,$i,Hex(-$i),$tstruct) produces: Acknowledgements Melba23, Kafu, ProgAndy, jchd1 point