Popular Post LarsJ Posted February 9, 2020 Popular Post Share Posted February 9, 2020 (edited) To make it easier to maintain the UIA code, I've decided to split the code this way: This new thread is used for the actual UIA UDFs. Ie. the files stored in Includes folders and named UIA_*.au3 or UIAEH_*.au3. The UIASpy thread contains only code that is used directly in the UIASpy GUI, but not the UIA UDFs in this new thread. Using UIA Code contains only example code, but neither UIA UDFs nor UIASpy. UIA Events contains GUI code to detect events and it contains example code, but neither UIA UDFs nor UIASpy. This means that every time the code in the UDF files in this new thread is updated (eg. because of Windows 10 feature updates twice a year), you must install the files in the Includes folders in the other threads yourself. The easiest way is simply to copy all UDF files to the Includes folders. UDF Files CUIAutomation2.au3 - UIA constants for Windows 7 used in the first examples CUIAutomation2-a.au3 - The original UIA constants for Windows 7 from junkew's thread UIA_AccVars.au3 - Used to calculate properties of type VT_UNKNOWN, copied and modified from this thread UIA_Constants.au3 - UIA constants (copied from UIA header files) up to and including Windows 10 1809 UIA_ConstNames.au3 - Contains functions for converting UIA constants from values to names UIA_Functions.au3 - A collection of small utility functions UIA_Functions-a.au3 - First version of utility functions UIA_ObjectFromTag.au3 - Creates callback objects used in event handlers, copied and modified from this post by trancexx UIA_SafeArray.au3 - Constants and functions to handle safearrays, copied from this thread UIA_Variant.au3 - Constants and functions to handle variants, copied from this thread UIAEH_AutomationEventHandler.au3 - Implements the AutomationEventHandler UIAEH_FocusChangedEventHandler.au3 - Implements the FocusChangedEventHandler UIAEH_NotificationEventHandler.au3 - Implements the NotificationEventHandler, published in Windows 10 1709 UIAEH_PropertyChangedEventHandler.au3 - Implements the PropertyChangedEventHandler UIAEH_StructureChangedEventHandler.au3 - Implements the StructureChangedEventHandler Folders The UI Automation projects can be stored in a folder structure this way: UI Automation\ Code\ - Using UIA code Events\ - UIA events Spy tool\ - UIASpy.au3 UDFs\ - UDF files The UDF files must be installed in Includes\ in the first three folders. Threads UIASpy - UI Automation Spy Tool is a GUI tool that provides information about windows and controls and their interconnection and provides functionality to generate sample code. UIASpy is essential for creating UI Automation code. In Using UI Automation Code in AutoIt you can find and download examples and read information about using UIA code. UI Automation Events is about implementing event handlers and includes GUIs to detect events. IUIAutomation MS framework automate chrome, FF, IE, .... created by junkew August 2013 is the first AutoIt thread on UIA code. Zip-file The zip contains source code for the UDF files. You need AutoIt 3.3.12 or later. Tested on Windows XP, Windows 7 and Windows 10. Comments are welcome. Let me know if there are any issues. UIAIncludes.7z Edited February 9, 2020 by LarsJ ioa747, FrancescoDiMuro, mLipok and 8 others 7 4 Controls, File Explorer, ROT objects, UI Automation, Windows Message MonitorCompiled code: Accessing AutoIt variables, DotNet.au3 UDF, Using C# and VB codeShell menus: The Context menu, The Favorites menu. Shell related: Control Panel, System Image ListsGraphics related: Rubik's Cube, OpenGL without external libraries, Navigating in an image, Non-rectangular selectionsListView controls: Colors and fonts, Multi-line header, Multi-line items, Checkboxes and icons, Incremental searchListView controls: Virtual ListViews, Editing cells, Data display functions Link to comment Share on other sites More sharing options...
polarole Posted November 14, 2020 Share Posted November 14, 2020 hi, i tried to use the UIASpy and installed the files as suggested, the script compiles succesfully, but the gui doesnt show up. whats wrong there? Link to comment Share on other sites More sharing options...
Developers Jos Posted November 14, 2020 Developers Share Posted November 14, 2020 3 hours ago, polarole said: i tried to use the UIASpy and installed the files as suggested, the script compiles succesfully, but the gui doesnt show up. whats wrong there? Line 20 of your script maybe? Spoiler Seriously: Provide all required details, like script and explain what you are trying to do, when you want to get some real support here. Jos SciTE4AutoIt3 Full installer Download page - Beta files Read before posting How to post scriptsource Forum etiquette Forum Rules Live for the present, Dream of the future, Learn from the past. Link to comment Share on other sites More sharing options...
polarole Posted November 14, 2020 Share Posted November 14, 2020 i am running UIASpy_Gui.au3 in the SciTe Editor and when i hit go i get: >"D:\Program Files (x86)\AutoIt3\SciTE\..\AutoIt3.exe" "D:\Program Files (x86)\AutoIt3\SciTE\AutoIt3Wrapper\AutoIt3Wrapper.au3" /run /prod /ErrorStdOut /in "D:\Program Files (x86)\AutoIt3\Include\Spy_tool\Includes\GuiIncludes\UIASpy_Gui.au3" /UserParams +>17:00:42 Starting AutoIt3Wrapper (19.1127.1402.0} from:SciTE.exe (4.2.0.0) Keyboard:00000407 OS:WIN_10/ CPU:X64 OS:X64 Environment(Language:0407) CodePage:0 utf8.auto.check:4 +> SciTEDir => D:\Program Files (x86)\AutoIt3\SciTE UserDir => C:\Users\Olfa\AppData\Local\AutoIt v3\SciTE\AutoIt3Wrapper SCITE_USERHOME => C:\Users\Olfa\AppData\Local\AutoIt v3\SciTE >Running AU3Check (3.3.14.5) from:D:\Program Files (x86)\AutoIt3 input:D:\Program Files (x86)\AutoIt3\Include\Spy_tool\Includes\GuiIncludes\UIASpy_Gui.au3 +>17:00:43 AU3Check ended.rc:0 >Running:(3.3.14.5):D:\Program Files (x86)\AutoIt3\autoit3_x64.exe "D:\Program Files (x86)\AutoIt3\Include\Spy_tool\Includes\GuiIncludes\UIASpy_Gui.au3" +>Setting Hotkeys...--> Press Ctrl+Alt+Break to Restart or Ctrl+BREAK to Stop. +>17:00:43 AutoIt3.exe ended.rc:0 +>17:00:43 AutoIt3Wrapper Finished. >Exit code: 0 Time: 1.786 But no Gui is opening? Thats better? Link to comment Share on other sites More sharing options...
LarsJ Posted November 14, 2020 Author Share Posted November 14, 2020 (edited) Initially, it's not necessary to compile the code. Just run the script in SciTE with F5. I'm pretty sure you installed the code incorrectly or run the code incorrectly. In the Folders section above, a folder structure for installing the code is suggested. Please install the code in this structure at least until you've got it working. Download and extract UIAIncludes.7z above in the ...\UI Automation\UDFs folder. The ...\UI Automation\UDFs\Includes folder should now contain 15 au3-scripts. Download and extract UIASpy.7z in the "...\UI Automation\Spy tool" folder. In ...\UI Automation\Spy tool\Includes you'll see a text file, Includes.txt, with the following content: Copy include files from UI Automation UDFs to this folder: https://www.autoitscript.com/forum/index.php?showtopic=??????? The easiest way is simply to copy all include files to this folder. Copy all 15 files from ...\UI Automation\UDFs\Includes to ...\UI Automation\Spy tool\Includes. Open ...\UI Automation\Spy tool\UIASpy.au3 in SciTE and run the script with F5. Note that UI Automation code isn't AutoIt main stream code. It's more difficult to use than the built-in automation functions. To get started, read Using UI Automation Code in AutoIt. Edited November 14, 2020 by LarsJ Controls, File Explorer, ROT objects, UI Automation, Windows Message MonitorCompiled code: Accessing AutoIt variables, DotNet.au3 UDF, Using C# and VB codeShell menus: The Context menu, The Favorites menu. Shell related: Control Panel, System Image ListsGraphics related: Rubik's Cube, OpenGL without external libraries, Navigating in an image, Non-rectangular selectionsListView controls: Colors and fonts, Multi-line header, Multi-line items, Checkboxes and icons, Incremental searchListView controls: Virtual ListViews, Editing cells, Data display functions Link to comment Share on other sites More sharing options...
polarole Posted November 17, 2020 Share Posted November 17, 2020 (edited) hi, it works now. thanks for helping. i also started working through the axamples they are very helpfull. Edited November 17, 2020 by polarole LarsJ 1 Link to comment Share on other sites More sharing options...
vergil250493 Posted February 8 Share Posted February 8 C:\Program Files (x86)\AutoIt3\Include\UIASpy_ElemInfo.au3 (2) : ==> Error opening the file.: #include "..\UIA_AccVars.au3" can share ? Link to comment Share on other sites More sharing options...
Recommended Posts
Create an account or sign in to comment
You need to be a member in order to leave a comment
Create an account
Sign up for a new account in our community. It's easy!
Register a new accountSign in
Already have an account? Sign in here.
Sign In Now