@m7modg97 wrote:
I’m trying to enable Bluetooth if it is not enabled, firstly I check if Bluetooth enabled, if not I try to enable it.
There is my code ://Check If Bluetooth Enabled Or Not this.bluetoothSerial.isEnabled().then( function() { alert("YES"); }, function() { alert("NO"); this.enableBluetooth(); } )
“enableBluetooth” function :
enableBluetooth(){ this.bluetoothSerial.enable().then( success => { alert("Bluetooth is enabled"); }, failure => { alert("The user did *not* enable Bluetooth"); } ); }
I run the application through “Ionic DevApp”.
If I run on chrome browser I get this error in console:
Device: Android.
Used Library: https://ionicframework.com/docs/native/bluetooth-serial
Posts: 1
Participants: 1