|
马上加入TC
您需要 登录 才可以下载或查看,没有帐号?立即注册
x
就是向记事本发送字串符,比如开两个记事本,这个运行了,刚才开那个就不运行了,下面是代码
namespace 多开
//默认空间
ts=array[]
hwnd=array[]
thhwnd=array[]
function sendstr(handle)
var index
index=arraysp.find(hwnd,handle)
ret=ts[index].bindwindow(hwnd[index],"gdi","windows","windows",1)
ts[index].lockinput(1)
while(ret)
ts[index].sendstring(hwnd[index],"I love you \n")
help.sleep(500)
endwhile
return 0
endfunction
function hotkey1_onhotkey()
//这里添加你要执行的代码
handle=window.getmousemovewndhand()
天使对象=com("ts.tssoft")
arraysp.add(ts,天使对象)
arraysp.add(hwnd,handle)
ctthread=thread.beginthread("多开.sendstr",handle)
arraysp.add(thhwnd,ctthread)
endfunction
function hotkey0_onhotkey()
//这里添加你要执行的代码
var index
handle=window.getmousemovewndhand()
index=arraysp.find(hwnd,handle)
ts[index].unbindwindow()
thread.closethread(thhwnd[index])
arraysp.deleteat(ts,index)
arraysp.deleteat(hwnd,index)
arraysp.deleteat(thhwnd,index)
endfunction
endnamespace
//空间结束 |
|