从 DEV_BROADCAST_DEVICEINTERFACE win32 编程访问 dbcc_name [英] acessing dbcc_name from DEV_BROADCAST_DEVICEINTERFACE win32 programming

查看:24
本文介绍了从 DEV_BROADCAST_DEVICEINTERFACE win32 编程访问 dbcc_name的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述

我有一些 c 代码可以检测 USB 电缆的拔出和插入.

I have some c code with me which detects the usb cable removal and insertion.

我发现了一个结构 DEV_BROADCAST_DEVICEINTERFACE,它的成员是 dbcc_name.但我不知道将哪个指针类型转换为该结构以访问 dbcc_name.

I found one structure DEV_BROADCAST_DEVICEINTERFACE which is having dbcc_name as member. but I don't know which pointer to type cast to this structure to access dbcc_name.

如何获取插入设备的设备名称.

How can I get the device name of the inserted device.

推荐答案

请注意 CodeSet.如果是 Unicode.数据为\\0......

Please notice the CodeSet. If it is Unicode. The data is \\0......

这篇关于从 DEV_BROADCAST_DEVICEINTERFACE win32 编程访问 dbcc_name的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!

查看全文
登录 关闭
扫码关注1秒登录
发送“验证码”获取 | 15天全站免登陆