fastnick1oo Posted January 15, 2009 Share Posted January 15, 2009 (edited) v0.1:#NoTrayIcon $hWin = WinGetHandle("[TITLE:µTorrent 1.8.1]") If $hWin == "" Then MsgBox(16, Default, "Couldn't find µTorrent window.", 5) Exit EndIf $hControl = ControlGetHandle($hWin, "", "[CLASS:SysListView32; INSTANCE:2]") ControlClick($hWin, "", $hControl, "left", 1, 5, 5); all $hControl = ControlGetHandle($hWin, "", "[CLASS:SysListView32; INSTANCE:3]") Do $shutDown = 1 $count = ControlListView($hWin, "", $hControl, "GetItemCount") If $count == 0 Then MsgBox(48, Default, "List is empty.", 5) Exit EndIf For $i = 0 To $count-1 If Number(ControlListView($hWin, "", $hControl, "GetText", $i, 3)) < 100 Then $shutDown = 0; procent If Number(ControlListView($hWin, "", $hControl, "GetText", $i, 11)) < 1.5 Then $shutDown = 0; ratio Next If Not $shutDown Then Sleep(Random(1, 2, 1)*1000) Until $shutDown If Not @Compiled Then MsgBox(0, Default, "Cya!", 5) Exit EndIf $PID = WinGetProcess($hWin) Do ProcessClose($PID) Sleep(250) Until Not ProcessExists($PID) Shutdown(1)Now... let's get some sleep, shall we? ; )edit: I've added more user-friendly version as attachment._Torrent_script_v0.2.au3 Edited January 15, 2009 by fastnick1oo SciTE - much better than notepad. ; ] Link to comment Share on other sites More sharing options...
Manko Posted January 16, 2009 Share Posted January 16, 2009 Nice idea! 'Tis what scripting is all about. But, uTorrent comes with this functionality, doesn't it? So you might not get many comments. Keep scripting! /Manko Yes i rush things! (I sorta do small bursts inbetween doing nothing.) Things I have rushed and reRushed:* ProDLLer - Process manager - Unload viri modules (dll) and moore...* _WinAPI_ProcessListOWNER_WTS() - Get Processes owner list...* _WinAPI_GetCommandLineFromPID() - Get commandline of target process...* _WinAPI_ThreadsnProcesses() Much info if expanded - optional Indented "Parent/Child"-style Processlist. Moore to come... eventually... Link to comment Share on other sites More sharing options...
iHonda Posted January 17, 2009 Share Posted January 17, 2009 mm tell us about it? A great place to start Autoit 1-2-3 Link to comment Share on other sites More sharing options...
Recommended Posts
Create an account or sign in to comment
You need to be a member in order to leave a comment
Create an account
Sign up for a new account in our community. It's easy!
Register a new accountSign in
Already have an account? Sign in here.
Sign In Now