06-05-2017, 06:26 PM
This is my approach. It is tested and it works properly :
Function tempf15
Function tempf15
,str stf ;; String to find
,ARRAY(str) ak ;; IStringmap key array
;,...............................
,stf="Dial"
,for int'i 0 ak.len
,,str stc=F"(?m)^\Q{stf}\E"
,,if(findrx(ak[i] stc)<0); continue
,,out F"{ak[i]}"
,,int w=win("QM - SES Help Topics" "#32770")
,,int c=id(4 w) ;;list
,,SendMessage c LVM_ENSUREVISIBLE i 0
,,Acc a.Find(w "LISTITEM" ak[i] "class=SysListView32[]id=4" 0x1005)
,,err
,,,out "String cannot be accessed"
,,,end
,,act c
,,a.Select(SELFLAG_TAKEFOCUS|SELFLAG_TAKESELECTION)
,,break
,if i=ak.len
,,outt F"String not found : {stf}"
,,ret
,