MeterThresholdEventArgs
Namespace: Wisej.Web
Assembly: Wisej.Framework (4.2.0.0)
Describes one absolute threshold boundary crossed because MeterBar.Value changed.
- C#
- VB.NET
public class MeterThresholdEventArgs : EventArgs
Public Class MeterThresholdEventArgs
Inherits EventArgs
Derives from or implements EventArgs.
Use From, Tone, OldValue to access the event data.
Example:
var meter = new MeterBar();
meter.Thresholds.Add(new MeterThreshold(75, MeterTone.Warning));
meter.ThresholdCrossed += (sender, e) =>
MessageBox.Show($"Boundary {e.From}: {e.OldValue} to {e.NewValue}; upward: {e.IsIncreasing}");
meter.Value = 80;
Constructors
MeterThresholdEventArgs(from, tone, oldValue, newValue)
Initializes immutable information about a threshold crossing.
| Name | Type | Description |
|---|---|---|
| from | Double | Absolute boundary that was crossed. |
| tone | MeterTone | Tone associated with that boundary at the time of crossing. |
| oldValue | Double | Usage before the change, in the meter's units. |
| newValue | Double | Usage after the change, in the meter's units. |
Properties
From
Double: Gets the absolute boundary crossed, in the meter's units.
IsIncreasing
Boolean: Gets whether usage crossed upward into the threshold.
NewValue
Double: Gets usage after the change.
OldValue
Double: Gets usage before the change.
Tone
MeterTone: Gets the boundary's tone, which is not necessarily the final active tone.