Show / Hide Table of Contents

Method timer2.every


Overload

Creates and starts new periodic timer.

public static timer2 every(long milliseconds, Action<timer2> timerAction, object tag = null, long? firstAfter = null)
Parameters
milliseconds  (long)

Time interval (period) of calling the callback function. Valid values are 0 - System.UInt32.MaxValue - 2.

timerAction  (Action<timer2>)

Callback function.

tag  (object)

Something to pass to the callback function as timer2.Tag.

firstAfter  (long?)

null (default) or time interval after which to call the callback function first time. Valid values are 0 - System.UInt32.MaxValue - 2.

Returns
timer2
Exceptions
ArgumentOutOfRangeException

Remarks

Calls System.Threading.Timer.Change.