westsan Posted August 22, 2007 Share Posted August 22, 2007 I would appreciate if someone could give me a few hints as how to time multiple steps in a long series of steps and output the time to a file so that it can be compared. For example I am testing iTunes with different types and volumes of data. I want to run the random series or normal user cases and output how long each step takes (DL, transfer to collection/playlists, delete, transfer data to iPod, etc.) I am a complete beginner TIA Link to comment Share on other sites More sharing options...
martin Posted August 22, 2007 Share Posted August 22, 2007 (edited) I would appreciate if someone could give me a few hints as how to time multiple steps in a long series of steps and output the time to a file so that it can be compared.For example I am testing iTunes with different types and volumes of data. I want to run the random series or normal user cases and output how long each step takes (DL, transfer to collection/playlists, delete, transfer data to iPod, etc.)I am a complete beginner TIAYou need to read up on Timerinit, Timerdiff, @MIN, @Sec, @Hour and related for timings, Fileopen, FileWriteLine, FileClose for the File IO and play with them.EDIT:Spelling Edited August 22, 2007 by martin Serial port communications UDF Includes functions for binary transmission and reception.printing UDF Useful for graphs, forms, labels, reports etc.Add User Call Tips to SciTE for functions in UDFs not included with AutoIt and for your own scripts.Functions with parameters in OnEvent mode and for Hot Keys One function replaces GuiSetOnEvent, GuiCtrlSetOnEvent and HotKeySet.UDF IsConnected2 for notification of status of connected state of many urls or IPs, without slowing the script. Link to comment Share on other sites More sharing options...
westsan Posted August 23, 2007 Author Share Posted August 23, 2007 Thanks. Im working on it.Is there a more complete reference than the AutoIt3 DocumentationIm not finding good explanatins (for a layman) there Link to comment Share on other sites More sharing options...
westsan Posted September 5, 2007 Author Share Posted September 5, 2007 Im not finding any examples anywere in the syntax required to use Timerdiff and Timerinit Link to comment Share on other sites More sharing options...
westsan Posted September 5, 2007 Author Share Posted September 5, 2007 Wait a minute: I just found the WinWaitActive command but I do not understand how I can use these: text [optional] The text of the window to check. timeout [optional] Timeout in seconds WinWaitActive ( "title" [, "text" [, timeout]] ) I would like to output the time it takes to be active Link to comment Share on other sites More sharing options...
PsaltyDS Posted September 5, 2007 Share Posted September 5, 2007 (edited) Wait a minute: I just found the WinWaitActive command but I do not understand how I can use these: text [optional] The text of the window to check. timeout [optional] Timeout in seconds WinWaitActive ( "title" [, "text" [, timeout]] ) I would like to output the time it takes to be active WinWaitActive() will not give you time elapsed. You need your own timer. TimerInit() takes no parameters at all, and only initializes a variable you provide. TimerDiff() only takes one parameter, the variable you previously initialized with the "start time", and returns the elapsed time in milliseconds. Run("notepad.exe") $Timer = TimerInit() WinWaitActive("Untitled - Notepad", "") $Elapsed = TimerDiff($Timer) MsgBox(64, "Time", "Notepad took " & $Elapsed / 1000 & " seconds to become active.") Edited September 5, 2007 by PsaltyDS Valuater's AutoIt 1-2-3, Class... Is now in Session!For those who want somebody to write the script for them: RentACoder"Any technology distinguishable from magic is insufficiently advanced." -- Geek's corollary to Clarke's law 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