jforr

Tooltips from second page?

1 post in this topic

I'm attempting to read through all of the tooltips on all controls of a page to find the control with the correct tooltip text that I want, and then click on that control.  I'm having a problem in that there is a scroll bar on my page and the WinList() function is only returning tooltips from the first page.  If I create a mouseclick to start on the second page before even grabbing the WinList() it still only picks from the first page.  The test code below is only meant to grab the tooltips and print them to the console, but can someone take a look and see if I've missed something obvious?

 

#include <Array.au3>
#include <WindowsConstants.au3>
#include <GuiToolTip.au3>
#include <WinAPI.au3>
#Include <Misc.au3>

Global $sLastTitle

Global $hWnd = WinWait("[CLASS:MedentClient]", "", 10)
WinActivate($hWnd)
If Not IsHWnd($hwnd) Then Exit ; exit if above handle invalid
Global $aWL = WinList("[CLASS:tooltips_class32]")

For $i1 = 1 To $aWL[0][0]
    $iTipCount = _GUIToolTip_GetToolCount($aWL[$i1][1]) ; get tooltip count per tool control
    For $i2 = 0 To $iTipCount -1 ; enumerate all tooltips for a tooltip control
        $aRet = _GUIToolTip_EnumTools($aWL[$i1][1], $i2)
        ConsoleWrite($aRet[8] & @CRLF)
    Next
Next

 

Share this post


Link to post
Share on other sites



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 account

Sign in

Already have an account? Sign in here.


Sign In Now