Connect to a paired Bluetooth device from C#.

PolarGoose 11 Reputation points
2022-02-01T18:40:41.643+00:00

It is a duplicate of my question on StackOverflow.
There is a "Connect" and "Disconnect" buttons in Windows Bluetooth settings.
170321-image.png
I want to create a console application which would make Windows connect and disconnect from my Bluetooth Headphones or other Bluetooth devices. However, I can't find a proper API to do that.
I have done some investigation described here but none of the ways I have found worked.

Could you help me finding a proper API or a workaround?

Windows development | Windows API - Win32
Developer technologies | C#
{count} votes

Your answer

Answers can be marked as Accepted Answers by the question author, which helps users to know the answer solved the author's problem.