SalTimer
Namespace: PPJ.Runtime.Windows
Assembly: PPJ.Web.50 (5.0.0.0)
Raises periodic SAL timer actions for an owning Wisej control.
- C#
- VB.NET
public class SalTimer : Timer
Public Class SalTimer
Inherits Timer
Each tick dispatches Sys.SAM_Timer with the timer identifier in the first message parameter, then raises the inherited tick event. The timer is disposed when its owner is disposed.
Example:
var timer = new PPJ.Runtime.Windows.SalTimer(owner, 1);
timer.Interval = 1000;
timer.Start();
// Later, stop and release the timer.
timer.Stop();
timer.Dispose();
Constructors
SalTimer(control, id)
Creates and registers a timer with its owning control.
| Name | Type | Description |
|---|---|---|
| control | Control | The control that receives timer actions and owns the timer's lifetime. |
| id | Int32 | The identifier included in timer actions and used to register the timer on the control. |
Throws:
- ArgumentNullException control is .
Methods
Dispose(disposing)
Removes the timer's registration from its owner and releases timer resources.
| Parameter | Type | Description |
|---|---|---|
| disposing | Boolean | to clear the owner registration while disposing managed resources; otherwise, . |
OnTick(e)
Dispatches the owner's SAL timer action before raising the inherited tick event.
| Parameter | Type | Description |
|---|---|---|
| e | EventArgs | The tick event data. |