CheckStopwatch()

Summary

Determines the elapsed time since a stopwatch started.

Syntax

elapsed_time = CheckStopwatch(string stopwatch_name)

Argument Contents
stopwatch_name Name of the stopwatch

Returns

A real number indicating the time in seconds since the stopwatch was created.

Example

CreateStopwatch("test my macro")
RunMacro("my macro")
time = CheckStopwatch("test my macro")
ShowMessage("The macro took " + String(time) + " seconds.")
DestroyStopwatch("test my macro")

Error Codes

Error Type Meaning
NotFound The specified stopwatch does not exist

See Also

Function Summary
CreateStopwatch() Start a stopwatch to track clock time
DestroyStopwatch() Stops or cancels a stopwatch
CreateTimer() Sets up a timer that executes a macro at fixed-time intervals
DestroyTimer() Cancels a timer that executes a macro at fixed-time intervals
Pause() Uses a timer to go into a waiting loop that yields to other processes, allowing Windows messages to be dispatched while waiting
Sleep() Uses a timer to go into a busy waiting loop that yields to other processes