11-16-2021, 12:27 AM
I feel like I've been asking too many questions. I have made a lot of progress and have figured out almost everything I need to be "feature-parity" with all the QM2 stuff I've created & re-used for automation on a daily basis.. One that is troubling me is scrolling to an element that happens to be hidden / off screen.
The ScrollTo method seems to be the ticket, but if I use Elm.Find to locate the item, it doesn't seem to work. Adding the EFFlags.UIA flag sometimes works, but causes collateral damage (invoke method doesn't work for example). Other times adding the flag fails to find the element at all.
In QM2 I had a global function I created like this:
I'm wondering if there's an alternate approach to "scroll". elm.Focus() sometimes works. But in the case of SysListView32, I have mixed results with the Focus method. Sometimes the element will get "selected" but the window doesn't scroll to that element.
Thoughts? (and I think this is my last one for a while and I really hope my pain in figuring stuff out helps someone else when searching the forum).
The ScrollTo method seems to be the ticket, but if I use Elm.Find to locate the item, it doesn't seem to work. Adding the EFFlags.UIA flag sometimes works, but causes collateral damage (invoke method doesn't work for example). Other times adding the flag fails to find the element at all.
In QM2 I had a global function I created like this:
I'm wondering if there's an alternate approach to "scroll". elm.Focus() sometimes works. But in the case of SysListView32, I have mixed results with the Focus method. Sometimes the element will get "selected" but the window doesn't scroll to that element.
Thoughts? (and I think this is my last one for a while and I really hope my pain in figuring stuff out helps someone else when searching the forum).