在 Windows 设备管理器中以编程方式卸载设备 [英] Programmatically uninstall a device in windows device manager

查看:63
本文介绍了在 Windows 设备管理器中以编程方式卸载设备的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述

是否可以在 Windows 中以编程方式卸载设备并以编程方式执行扫描硬件更改"?是否有任何可以用于相同目的的 VB 脚本?或者有没有可以调用的windows API来实现?

Is it possible to programmatically uninstall a device in windows and perform a 'scan for hardware changes' programmatically? Is there any VB script that can be used for the same? Or is there any windows API that can be called to achieve the same?

推荐答案

强制扫描硬件更改"签出如何从应用程序强制重新枚举设备树" 此处的示例显示了如何强制重新枚举整个树.

To force the 'scan for hardware changes' checkout "How To Force Reenumeration of a Device Tree From an Application" the sample there shows how to force the entire tree to be re-enumerated.

关于删除驱动程序检出 DiUninstallDevice.

As to removing a driver checkout DiUninstallDevice.

这篇关于在 Windows 设备管理器中以编程方式卸载设备的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!

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