I want to update my mirror driver using “devcon.exe”, but the .dll file and the .sys file never get updated. After sometime’s work, I found out that after I installed the mirror driver the very first time, there is a new folder named “mirror.inf_x86_neutral_ad308b1aac5d229b” created under "…\system32\DriverStore\FileRepository" with the .inf, .dll and .sys file copied into the newly created folder. And as long as this folder exists, I can’t replace the old driver files with my new driver files. I know when I uninstall the driver in device manager and check the checkbox “Delete the driver software for this device” then after I restart the system, the folder I mentioned above will disappear and then I can replace the old driver files with the new ones after I install my new Mirror Driver.
The question is, I wanna remove the old driver through a program, not by hand, but I can’t find a way of the same effect of check the checkbox “Delete the driver software for this device”.
Does anybody else have some idea about it?
You can use dpinst.exe /u <oemxx.inf> command where oemxx.inf refers to a
file in windows\inf directory. oemxx.inf is created when you installed the
mirror driver. You can locate this file by looking at the mirror driver inf
because content of oemxx.inf would be exactly same to your mirror driver
inf.
You can write a small utility by using SetupUninstallOEMInf() api (refer
msdn for help) also to remove the driver package from driver store.
Thanks,
Prashant
On Fri, Nov 27, 2009 at 3:06 PM, <328192084@163.com> wrote:
> I want to update my mirror driver using “devcon.exe”, but the .dll file and
> the .sys file never get updated. After sometime’s work, I found out that
> after I installed the mirror driver the very first time, there is a new
> folder named “mirror.inf_x86_neutral_ad308b1aac5d229b” created under
> "…\system32\DriverStore\FileRepository" with the .inf, .dll and .sys file
> copied into the newly created folder. And as long as this folder exists, I
> can’t replace the old driver files with my new driver files. I know when I
> uninstall the driver in device manager and check the checkbox “Delete the
> driver software for this device” then after I restart the system, the folder
> I mentioned above will disappear and then I can replace the old driver files
> with the new ones after I install my new Mirror Driver.
> The question is, I wanna remove the old driver through a program, not by
> hand, but I can’t find a way of the same effect of check the checkbox
> “Delete the driver software for this device”.
> Does anybody else have some idea about it?
>
> —
> NTDEV is sponsored by OSR
>
> For our schedule of WDF, WDM, debugging and other seminars visit:
> http://www.osr.com/seminars
>
> To unsubscribe, visit the List Server section of OSR Online at
> http://www.osronline.com/page.cfm?name=ListServer
></oemxx.inf>
Thanks very much, Prashant!
I tried your advice and it worked!
Thanks!