How to Run Installs from .INF Files
Keywords: rundll32.exe setupapi,InstallHinfSectionDefaultInstall
Question:
How do I run an install in Windows 95 from an *.INF file?
How can I install a .inf file from the command line?
Answer:
The normal method to install a .inf file is to right click on it and select Install from the context menu however it is also possible to install from the command line.
The syntax is:
C:\> rundll32 syssetup,SetupInfObjectInstallAction DefaultInstall 128 .\.inf
Another user reports:
I can tell you the syntax we are using for NT, I assume it will work with 95 but I
can't confirm.
runshell("c:\winnt\system32\rundll32.exe","setupapi,InstallHinfSectionDefaultInstall 128 filename.ext", "c:\winnt\system32", @hidden, @WAIT)
Example to install the DosHere PowerToy:
Str1 = 'c:\temp\doshere.inf' ; full path to INF file
RunWait( 'rundll32', StrCat( 'syssetup,SetupInfObjectInstallAction DefaultInstall 128 ', Str1 ) )
Related Question:
I have a program that installs via an .inf file. Can I simulate the RMouse click and install
it via WinBatch?
Answer:
Something like:
inffile="c:\whereever\doit.inf"
infpath=FilePath(inffile)
ShellExecute(inffile,"",infpath,@NORMAL,"Install")
Article ID: W13405
Filename: Run Installs from INF Files.txt