I want to get text from a dialog box. I am getting the title from the dialog box using
My code in autoit is as follows:
$pId = Run("C:/foldername/Dialogbox.exe") Local $hWnd = WinWait("[CLASS:#32770]", "", 10) Local $sTitle = WinGetTitle("[ACTIVE]") ; Display the window title. ConsoleWrite($sTitle & @CRLF) ; changing control from the class containg title to the class containing the text. Local $hSysTray_Handle = ControlGetHandle('[Class:#32770]', '', '[Class:SysListView32;Instance:1]') Local $sText = WinGetText("[ACTIVE]") Local $sTextnew = ControlGetText($hSysTray_Handle, "", $sText) ConsoleWrite($sTextnew & @CRLF)
This returns only the title and not the text in the dialog box.
#32770 is the main class of dialog box and title, text are in the different classes in basic control info in autoit.
I am new to autoit and don't know how to fetch the text from dialog box. Or should I use sikuli for this?