I have written a simple application that runs to preinstall driver for the Windows XP such that if you plug in the device, the Add New Hardware Window would not appear.
I am able to perform this successfully when my driver has a valid catalog file, which means it is WHQL certifed.
But for non-WHQL certified drivers, I cannot seem to make this work. When I run SetupCopyOemInf, it always returns TRUE, which means the inf was successfully pre-installed. But when I plugged in the device, the Add New Hardware Window still appears.
So my question is, why does SetupCopyOEMInf return true even with drivers having no WHQL certification/ valid catalog file yet when you plug in the device, the Add New Hardware Window still appears?
/*in this case, result returns 1 (TRUE)*/
/*infPath points to the inf file path*/
/*execPath points to the path of where the inf is contained*/
result = SetupCopyOEMInf(