DispatcherTimer DispatcherTimer DispatcherTimer DispatcherTimer Constructors

Definition

Overloads

DispatcherTimer() DispatcherTimer() DispatcherTimer()

Initializes a new instance of the DispatcherTimer class.

DispatcherTimer(DispatcherPriority) DispatcherTimer(DispatcherPriority) DispatcherTimer(DispatcherPriority) DispatcherTimer(DispatcherPriority)

Initializes a new instance of the DispatcherTimer class which processes timer events at the specified priority.

DispatcherTimer(DispatcherPriority, Dispatcher) DispatcherTimer(DispatcherPriority, Dispatcher) DispatcherTimer(DispatcherPriority, Dispatcher)

Initializes a new instance of the DispatcherTimer class which runs on the specified Dispatcher at the specified priority.

DispatcherTimer(TimeSpan, DispatcherPriority, EventHandler, Dispatcher) DispatcherTimer(TimeSpan, DispatcherPriority, EventHandler, Dispatcher) DispatcherTimer(TimeSpan, DispatcherPriority, EventHandler, Dispatcher)

Initializes a new instance of the DispatcherTimer class which uses the specified time interval, priority, event handler, and Dispatcher.

DispatcherTimer() DispatcherTimer() DispatcherTimer()

Initializes a new instance of the DispatcherTimer class.

public:
 DispatcherTimer();
public DispatcherTimer ();
Public Sub New ()

Remarks

DispatcherTimer runs on the Dispatcher of the current thread at Background priority. To specify a different Dispatcher, use the following constructor: DispatcherTimer.DispatcherTimer(DispatcherPriority, Dispatcher).

DispatcherTimer(DispatcherPriority) DispatcherTimer(DispatcherPriority) DispatcherTimer(DispatcherPriority) DispatcherTimer(DispatcherPriority)

Initializes a new instance of the DispatcherTimer class which processes timer events at the specified priority.

public:
 DispatcherTimer(System::Windows::Threading::DispatcherPriority priority);
public DispatcherTimer (System.Windows.Threading.DispatcherPriority priority);
new System.Windows.Threading.DispatcherTimer : System.Windows.Threading.DispatcherPriority -> System.Windows.Threading.DispatcherTimer
Public Sub New (priority As DispatcherPriority)

Parameters

priority
DispatcherPriority DispatcherPriority DispatcherPriority DispatcherPriority

The priority at which to invoke the timer.

Remarks

DispatcherTimer runs on the Dispatcher of the current thread. To specify a different Dispatcher, use the following constructor: DispatcherTimer(DispatcherPriority, Dispatcher).

DispatcherTimer(DispatcherPriority, Dispatcher) DispatcherTimer(DispatcherPriority, Dispatcher) DispatcherTimer(DispatcherPriority, Dispatcher)

Initializes a new instance of the DispatcherTimer class which runs on the specified Dispatcher at the specified priority.

public:
 DispatcherTimer(System::Windows::Threading::DispatcherPriority priority, System::Windows::Threading::Dispatcher ^ dispatcher);
public DispatcherTimer (System.Windows.Threading.DispatcherPriority priority, System.Windows.Threading.Dispatcher dispatcher);
new System.Windows.Threading.DispatcherTimer : System.Windows.Threading.DispatcherPriority * System.Windows.Threading.Dispatcher -> System.Windows.Threading.DispatcherTimer

Parameters

priority
DispatcherPriority DispatcherPriority DispatcherPriority DispatcherPriority

The priority at which to invoke the timer.

dispatcher
Dispatcher Dispatcher Dispatcher Dispatcher

The dispatcher the timer is associated with.

Exceptions

DispatcherTimer(TimeSpan, DispatcherPriority, EventHandler, Dispatcher) DispatcherTimer(TimeSpan, DispatcherPriority, EventHandler, Dispatcher) DispatcherTimer(TimeSpan, DispatcherPriority, EventHandler, Dispatcher)

Initializes a new instance of the DispatcherTimer class which uses the specified time interval, priority, event handler, and Dispatcher.

public:
 DispatcherTimer(TimeSpan interval, System::Windows::Threading::DispatcherPriority priority, EventHandler ^ callback, System::Windows::Threading::Dispatcher ^ dispatcher);
public DispatcherTimer (TimeSpan interval, System.Windows.Threading.DispatcherPriority priority, EventHandler callback, System.Windows.Threading.Dispatcher dispatcher);
new System.Windows.Threading.DispatcherTimer : TimeSpan * System.Windows.Threading.DispatcherPriority * EventHandler * System.Windows.Threading.Dispatcher -> System.Windows.Threading.DispatcherTimer

Parameters

interval
TimeSpan TimeSpan TimeSpan TimeSpan

The period of time between ticks.

priority
DispatcherPriority DispatcherPriority DispatcherPriority DispatcherPriority

The priority at which to invoke the timer.

callback
EventHandler EventHandler EventHandler EventHandler

The event handler to call when the Tick event occurs.

dispatcher
Dispatcher Dispatcher Dispatcher Dispatcher

The dispatcher the timer is associated with.

Exceptions

Applies to