#Include GetChildHWND.ahk !z:: ;Number of geting string ;Note: First index=0 InputBox,N,Enter number of string, Retrieve text of N string in ListBox,,,,,,,, s=retrieval string VAR_address:= DllCall("CharNext", str, s, UInt)-1 ActiveWindow:= WinExist("A") WinGetClass, class, A ControlGetFocus, FocusedControl, ahk_id %ActiveWindow% if not FocusedControl return c_id:=GetChildHWND(ActiveWindow,FocusedControl) SendMessage, 0x189, N, VAR_address, %FocusedControl%, A ;MsgBox (Class=%class% Handle=%ActiveWindow%)(FC=%FocusedControl% Handle=%c_id%) MsgBox (retrieval string=%s%)