Jump to content

Getting a value from the Visible Text


Recommended Posts

Hi I am looking for a way to get value from Visible Text.

>>>> Window <<<<
Title:  NVIDIA Control Panel
Class:  Afx:00007FF6CFB40000:b:0000000000010007:0000000000000006:0000000002F21B43
Position:   965, 540
Size:   974, 620
Style:  0x14CF0000
ExStyle:    0x00010100
Handle: 0x0000000000B11C78

>>>> Control <<<<
Class:  Static
Instance:   26
ClassnameNN:    Static26
Name:   
Advanced (Class):   [CLASS:Static; INSTANCE:26]
ID: 206
Text:   
Position:   275, 113
Size:   953, 531
ControlClick Coords:    202, 73
Style:  0x5400000E
ExStyle:    0x00000004
Handle: 0x00000000004E1C9E

>>>> Mouse <<<<
Position:   1450, 777
Cursor ID:  0
Color:  0xF3F3F3

>>>> StatusBar <<<<

>>>> ToolsBar <<<<

>>>> Visible Text <<<<
D&isable SLI

 I'm looking to get the Value for D&isable SLI and then move my mouse to it. I'm having trouble with this because I can't use the Advanced Class because there are multiple buttons with the same class so i have to resort to using Visible Text.

Is this possible to do? I found some example code on the forum but I'm not sure how to use the RegExp

$Text=ControlGetText("[CLASS:Notepad]","","[CLASSNN:Edit1]")
$Value=StringSplit($Text,@CRLF)
For $i=1 To $Value[0]
    If StringRegExp($Value[$i],"[0-9][^:alpha:]") Then
        MsgBox(0,"",$Value[$i])
    EndIf
Next

That's the example.

Link to comment
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
 Share

×
×
  • Create New...