08-15-2007, 06:28 PM
Gintaras Wrote:Do you need them to run in same thread?
no, thats fine.
my main function is now:
TSK_Main
how do is start TSK_functions in an own thread with 3s repeat ?
TSK_functions
out
int um_hwnd=win("" "UltraMon Taskbar")
str s tb1 tb2 title cls exe; int hwnd htb1 htb2
ARRAY(int) handles
GetWindowList 0 "" 0 0 0 handles
for(int'i 0 handles.len)
,hwnd=handles[i]
,if(!IsWindowVisible(hwnd)) continue ;;exclude hidden
,if(GetWinStyle(hwnd 1)&WS_EX_TOOLWINDOW) continue
,exe.getwinexe(hwnd 1)
,title.getwintext(hwnd)
,cls.getwinclass(hwnd)
,title.findreplace(":" " ") ;;escape :
,title.escape(1) ;;escape "
,title.left(title 24)
,if taskbar_splitter(hwnd)==1
,,tb1.formata("%s - hwnd=%i[]" title hwnd)
,else
,,tb2.formata("%s - hwnd=%i[]" title hwnd)
,
out "left:[]%s[]right:[]%s" tb1 tb2