DWORD BluetoothSetServiceState(
HANDLE hRadio,
BLUETOOTH_DEVICE_INFO* pbtdi,
GUID* pGuidService,
DWORD dwServiceFlags
); 参数:
hRadio

A handle of the local Bluetooth radio.  本地蓝牙无线电的句柄。

pbtdi

A pointer to a BLUETOOTH_DEVICE_INFO structure. Must be a previously found radio address. 指向BLUETOOTH_DEVICE_INFO结构的指针。必须是以前找到的无线电地址。

pGuidService

A pointer to the service GUID on the remote device. 指向远程设备上的服务GUID的指针

dwServiceFlags

The flags that adjust the service. To disable the service, set to BLUETOOTH_SERVICE_DISABLE; to enable the service, set to BLUETOOTH_SERVICE_ENABLE.

调整服务的标志。要禁用服务,设置为BLUETOOTH_SERVICE_DISABLE;要启用该服务,请将其设置为BLUETOOTH_SERVICE_ENABLE。

返回值:

Returns ERROR_SUCCESS upon successful completion. The following table lists common errors.

成功完成后返回ERROR_SUCCESS。下表列出了常见的错误。

Return code Description

ERROR_INVALID_PARAMETER

The dwServiceFlags are not valid.      dwServiceFlags无效。

ERROR_SERVICE_DOES_NOT_EXIST

The GUID specified in pGuidService is not supported.   不支持pGuidService中指定的GUID

E_INVALIDARG

dwServiceFlags is set to BLUETOOTH_SERVICE_DISABLE and the service is already disabled, or dwServiceFlags is set to BLUETOOTH_SERVICE_ENABLE and the service is already enabled.

dwServiceFlags设置为BLUETOOTH_SERVICE_DISABLE,服务已经禁用,或者dwServiceFlags设置为BLUETOOTH_SERVICE_ENABLE,服务已经启用

Windows维护了服务全局惟一标识符(GUIDs)到支持蓝牙设备的驱动程序的映射。启用服务将安装相应的设备驱动程序,禁用服务将删除相应的设备驱动程序。如果启用了不支持的服务,则不会安装驱动程序。

Header

Declared in BluetoothAPIs.h; include Bthsdpdef.h and BluetoothAPIs.h.

Library

Use Bthprops.lib.

最新文章

  1. 在离线环境中使用.NET Core
  2. 【生活没有希望】NOIP2010初赛 烽火传递 smartoj1475
  3. Html5浏览器缓存 sessionStorage 与 localStorage
  4. Hive_初步见解,安装部署与测试
  5. 《灰帽Python-黑客和逆向工程师的Python编程》学习记录
  6. RecyclerView 详解
  7. 自由HTML5串行来到《HTML5具体解释Web开发的例子》连载(三)DOCTYPE和字符集
  8. vue-组件注册
  9. 2019.03.09 bzoj4491: 我也不知道题目名字是什么(线段树)
  10. Python:Day42 Position
  11. 广播频道-BroadcastChannel
  12. ogg跳过某个RBA
  13. 基于Java+SparkStreaming整合kafka编程
  14. redis 使用管道提升写入的性能[pipeline]
  15. HDU 4135 Co-prime 欧拉+容斥定理
  16. 第六章 JVM垃圾收集器(2)
  17. 使用 Feed43
  18. e668. 在一组像素中创建缓冲图像
  19. express 直接返回HTML文件
  20. MYSQL LOGBIN 数据日志恢复数据库随笔

热门文章

  1. POJ - 3414 Pots 【BFS】
  2. Python map,reduce,filter,apply
  3. Data Structure Stack: Infix to Postfix
  4. maven setting.xml 中文配置详解(全配置)
  5. CustomizaitonSpec Clone_VM
  6. Socket bind failed: [730048] ?????????×???(Э?é/???????/???)????í??错误
  7. Victor/ArrayList/LinkedList/Stack/CopyOnWriteArrayList 区别
  8. 属性 visibility
  9. 关于HttpURLConnection测试servlet
  10. 【python】关于函数递归使用 return 后,收到数据为 None。