Logo Questions Linux Laravel Mysql Ubuntu Git Menu
 

PnPutil commands to uninstall the display adapter driver does not work

I am currently trying to uninstall display adapter driver in power shell. I can simply go to device manager to find display adapter and uninstall the driver and then install the new driver. But I want to write an automated script to make it easy.

I tried to use "pnputil.exe -f -d oem##.inf" in power shell to uninstall the display adapter driver.

But it did not work and gave me something like that

"Deleting the driver package failed: One or more devices are presently installed using the specified INF"

Does anyone know how can I solve this problem and make pnputil work?

like image 771
John Avatar asked Oct 14 '25 18:10

John


1 Answers

This isn't a PowerShell question really, as it's a window util.

from running pnputil /?

/delete-driver <oem#.inf> [/force]
Delete driver package from the driver store.
/force - delete driver package even when it is in use by devices.

so running pnputil.exe /delete-driver oem##.inf /force should work for you.

like image 80
colsw Avatar answered Oct 17 '25 10:10

colsw



Donate For Us

If you love us? You can donate to us via Paypal or buy me a coffee so we can maintain and grow! Thank you!