cancel
Showing results for 
Show  only  | Search instead for 
Did you mean: 
andyamstrad
Level 6

Installing Device Drivers Vista

Im installing a signed device driver silently on Vista using the dpinst. The exit code is invalid basically because Vista is prompting do you want to installthis device driver, but Im installing silently.

Is there a work around or is the DIFX 2.10 utility a workable solution?
Labels (1)
0 Kudos
(8) Replies
Holger_G
Level 10

If your driver package has been signed successfully for Windows Vista you should be able to install the device driver package 'silently'. How do you call DPInst? What kind of InstallShield project do you use?
0 Kudos
andyamstrad
Level 6

Hi Nick

Im using a Basic Installshield Project.

These are the command lines

Sprintf(CmdLine, '/PATH "%s" /S /SW', INFFolder);

I have also used

Sprintf(CmdLine, '/PATH "%s" /Q', INFFolder);


If I install in UI mode it starts to install the device driver and then Vista pops up a message something like 'Device Driver Installation detected do you want to install or cancel'. In silent mode this cannot appear hence the -2147418112 error exit code I recieve from Installshields LaunchApplication function.

If I run the device driver install in UI mode and then re-run in silent mode I receive a 0 exit code.
0 Kudos
Holger_G
Level 10

What´s the main reason using DPInst instead of DIFxAPP which can be used inside Basic MSI projects for driver components. Have you tried that?
0 Kudos
andyamstrad
Level 6

Hi Nick

Main reason for using DPInst is that the project does not use Features and Components. The project uses custom tables in DirectEditor to dynamically create its own custom Features (Modules) and Components.

I have a copy of DIFX 2.10, would there be an advantage of using that? Failing that I will ensure the drivers are properly signed.
0 Kudos
Holger_G
Level 10

Normally UI mode does not have elevated privileges, so I suggest that´s the reason why DPInst fails. The requestedExecutionLevel of the embedded manifest of DPInst is set to 'highestAvailable'.

I would recommend to launch DPInst with a deferred custom action in system context.
0 Kudos
andyamstrad
Level 6

Hi Nick

I did want to try and avoid using a deferred CA, but seems I have no chocie at this point.

It now works with the CA type changed.

Thanks for your time and effort.
0 Kudos
Holger_G
Level 10

You could also use a InstallScript CA during the UI sequence using LaunchApplication with LAAW_OPTION_USE_SHELLEXECUTE
and 'runas' as the lpVerb of the SHELLEXECUTEINFO Structure.

That would launch the application with elevated privileges but would also raise UAC.
0 Kudos
andyamstrad
Level 6

Yes I may try that, thanks again for your help.
0 Kudos