Datalogic .NET SDK
GetBatteryThreshold (Method)
Syntax
public static Boolean GetBatteryThreshold(out BatteryThreshold batThreshold);
Description
Gets the warning threshold levels used for the main or backup battery.
Parameters Table
|
Type |
Parameter |
Description |
[out] |
BatteryThreshold |
batThreshold |
A Device.BatteryThreshold value. |
|
|
|
|
[returns] |
Boolean
|
|
TRUE if the function succeeds, FALSE otherwise. |
[on error] |
FALSE |
|
|
Example
private void btnBattThrSET_Click(object sender, EventArgs e) { bool b = false; Device.BatteryThreshold oBatteryThresh = new Device.BatteryThreshold(); Device.BatteryThreshold oBatteryThresh_Get = new Device.BatteryThreshold();
oBatteryThresh.Critical = (ushort)(int.Parse(txtSetBattThCrit.Text)); oBatteryThresh.Low = (ushort)(int.Parse(txtSetBattThLow.Text));
b = Device.SetBatteryThreshold(oBatteryThresh);
b = Device.GetBatteryThreshold(out oBatteryThresh_Get); }
|
See Also
Device.BatteryThreshold (Struct), Example #027.
Copyright © Datalogic ADC. All Right Reserved