Bluetooth Event problem

Scantech

Well-Known Member
Licensed User
Longtime User
I was experimenting with 2 BluetoothAdmin. Each with different Event name.

One is at service module and the other in the activity. In the service module i have a toast messages for enable/disable bt. The second bt event is empty. I enable/disable the activity bt, but the bt event in the service module gets raised. Is this a bug?
 

Erel

B4X founder
Staff member
Licensed User
Longtime User
The Bluetooth events are handled by intercepting broadcasted system messages. Only one receiver in each application can intercept each message. This means that the event will be raised by one of the BluetoothAdmins. You cannot even know which one.

Why do you need two objects? I recommend you to remove the one in the activity and use CallSubDelayed to call the service as needed.
 
Upvote 0

Scantech

Well-Known Member
Licensed User
Longtime User
I was trying to avoid the toast message and input list dialog in that event. I have a work around. Thanks for your time Erel.
 
Last edited:
Upvote 0
Top