I am successfully automatically pairing Bluetooth device against Win 7 and Win 10, using feet32 Library. Unfortunately a System Dialog shows up, saying "tap to pair" Under Win 7 it pairs if I Tap the Dialog or not. Under Win 10 it does not pair, if I do not touch the dialog.
Actually, there is a Win 10 option, that switches off the dialog, but then no pairing takes place also.
Under Win 7 handlerequests is called, under Win 10 it is not.
Under Win 7 it pairs anyway.
Dim pairer As New BluetoothWin32Authentication(AddressOf handleRequests )
Public Sub handleRequests(ByVal thing As Object, ByVal args As BluetoothWin32AuthenticationEventArgs)
args.Confirm = True
End Sub
Protected Function TryRemember(ByVal peer As BluetoothDeviceInfo) As Boolean
If peer Is Nothing Then Return False
Return BluetoothSecurity.PairRequest(peer.DeviceAddress, Nothing )
End Function
See Question&Answers more detail:
os 与恶龙缠斗过久,自身亦成为恶龙;凝视深渊过久,深渊将回以凝视…