Device.bluetoothUnpairAllPrinters()
Overview
Removes the system pairing for all Bluetooth printer devices.
Added in version 2.1.33
Android only
Format
var available = Device.bluetoothUnpairAllPrinters();
Parameter | Description | Type | Required | Notes |
---|---|---|---|---|
available | Indicates if the unpair process is available. | Boolean | Return value | A false return value indicates unpairing is unavailable at this time. |
Example
Copy
/* Tries to unpair all Bluetooth printer devices when the F1 key is pressed.
* Logs information on success or failure.
*/
WLEvent.onKey(0xE03B, function(event) {
var available = Device.bluetoothUnpairAllPrinters();
if(!available) {
Logger.error("Cannot unpair right now");
}
event.eventHandled = true;
});