hottehead 0 Posted August 31, 2020 Share Posted August 31, 2020 Hello, i have a list Box which shows somewhat like a table like below. When using _GUICtrlListBox_GetText ( https://www.autoitscript.com/autoit3/docs/libfunctions/_GUICtrlListBox_GetText.htm) i only get back Item1 / Item2 / Item3 depending on used index. The autoit window inspector also does not show the "Additonal" strings as visible content. Where are these strings? How can I access them? Quote ------------------------------------------------ Item1 Additonal1.1 Additional1.2 Item2 Additonal2.1 Additional2.2 Item3 Additonal3.1 Additional3.1 ------------------------------------------------ I noted one can use custom string-based ListBox using a special style. But I dont know how to handle those if this is my case. Link to post Share on other sites
Nine 1,501 Posted August 31, 2020 Share Posted August 31, 2020 It would be a good idea to provide a runable snippet of your code so we can see how you creating/manipulating the controls, etc. Please use this tool when posting code. Not much of a signature but working on it... Spoiler Block all input without UAC Save/Retrieve Images to/from Text Monitor Management (VCP commands) Tool to search content in au3 files Date Range Picker Virtual Desktop Manager Sudoku Game 2020 Overlapped Named Pipe IPC HotString 2.0 - Hot keys with string x64 Bitwise Operations Multi-keyboards HotKeySet Recursive Array Display Fast and simple WCD IPC Multiple Folders Selector GIF Animation (cached) Screen Scraping Link to post Share on other sites
Zedna 355 Posted August 31, 2020 Share Posted August 31, 2020 (edited) What is the ClassNameNN (shown in Au3Info) of your target ListBox control? And post screenshot of that ListBox's control/content ... Edited August 31, 2020 by Zedna Resources UDF ResourcesEx UDF AutoIt Forum Search Link to post Share on other sites
hottehead 0 Posted September 1, 2020 Author Share Posted September 1, 2020 Thanks for the answers 😃 The ClassnameNN is ListBox1 This is the code I'm using. The controls are being found and the windowHandle is also found. As said before I get a partial string of the visible text from each item. Local $listBox = ControlGetHandle($windowHandle, "", "[CLASS:ListBox; INSTANCE:1]") Local $item1 = _GUICtrlListBox_GetText($listBox, 0) The GUI is not build with AutoIt. There must be some deeper nested objects which are not triggered by GetText() but are triggered by the GUI render. Though the inspector does not show more nested controls within the ListBox Control. Link to post Share on other sites
Nine 1,501 Posted September 1, 2020 Share Posted September 1, 2020 What is the application ? Since we cannot test your code, you could try UIAutomation spy to see if it detects the other strings. Not much of a signature but working on it... Spoiler Block all input without UAC Save/Retrieve Images to/from Text Monitor Management (VCP commands) Tool to search content in au3 files Date Range Picker Virtual Desktop Manager Sudoku Game 2020 Overlapped Named Pipe IPC HotString 2.0 - Hot keys with string x64 Bitwise Operations Multi-keyboards HotKeySet Recursive Array Display Fast and simple WCD IPC Multiple Folders Selector GIF Animation (cached) Screen Scraping Link to post Share on other sites
hottehead 0 Posted September 2, 2020 Author Share Posted September 2, 2020 It's an rather unmaintained in-house app running on XP. It crashes regularly and needs to be restarted and rechecked for correct config. Thanks for the hint. I'll give UIAutomation spy a shot. Link to post Share on other sites
Nine 1,501 Posted September 2, 2020 Share Posted September 2, 2020 4 hours ago, hottehead said: in-house app running on XP. Oh, I don't think UIAutomation will help you much with such of an old software (but try it anyway, one never knows). Only suggestion that comes to me if UIA doesn't work, is to screen capture the region and use OCR to read the other strings. Not much of a signature but working on it... Spoiler Block all input without UAC Save/Retrieve Images to/from Text Monitor Management (VCP commands) Tool to search content in au3 files Date Range Picker Virtual Desktop Manager Sudoku Game 2020 Overlapped Named Pipe IPC HotString 2.0 - Hot keys with string x64 Bitwise Operations Multi-keyboards HotKeySet Recursive Array Display Fast and simple WCD IPC Multiple Folders Selector GIF Animation (cached) Screen Scraping Link to post Share on other sites
Dan_555 104 Posted September 2, 2020 Share Posted September 2, 2020 On 8/31/2020 at 5:35 PM, hottehead said: ------------------------------------------------ Item1 Additonal1.1 Additional1.2 Item2 Additonal2.1 Additional2.2 Item3 Additonal3.1 Additional3.1 ------------------------------------------------ This looks more like a ListView than a ListBox. Are you sure it is a ListBox ? Link to post Share on other sites
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