Jump to content

Recommended Posts

Posted

Any idea how to run a inf addOn from RunOnceEx?

So far I have have extracted any cab files in the addOn into the same folder as the inf and tried running the following from a command line:

rundll32 setupapi,InstallHinfSection DefaultInstall 128 setup.inf

Which resulted in the following "Files needed" notification:

post-611-1183820234_thumb.jpg

I think I have narrowed it down to the [sourceDisksNames.x86] entry in the inf. By deleting any reference to the .cab the installer seems to load with no "files needed" notifications. This has not been tested on a new install though it works on a pre loaded OS.

If any of the resident inf addOn makers have any suggestions, tips or tricks I would be greatly thankful.

-Thanks in advance

Posted
Can you post the inf file

Thanks for taking a look at this. Any of you or kel's addons that are not dependant on the T13 stage can be used as an example.

[Version]
Signature=$Windows NT$

[defaultinstall]
OptionDesc ="PowerMenu Visual Enhancement"
Tip ="PowerMenu"
Modes =0,1,2,3
CopyFiles =PowerMenu.copy
ADDReg =Start

[Optional Components]
PowerMenu

[PowerMenu]
OptionDesc ="PowerMenu Visual Enhancement"
Tip ="PowerMenu"
Modes =0,1,2,3
CopyFiles =PowerMenu.copy
ADDReg =Start

[uninstall]
BeginPrompt = BeginUnInsPrompt
EndPrompt = EndUnInsPrompt
RunPreSetupCommands=Kill.PowerMenu:1
DelFiles = PowerMenu.copy
DelReg = Start
DelDirs = folder.del

[Kill.PowerMenu]
taskkill.exe /IM PowerMenu.exe /F

[folder.del]
%16422%\%PowerMenu%

[BeginUnInsPrompt]
Prompt = %UninsQuest%
Title = %UninsTitle%
ButtonType = OKCANC

[EndUnInsPrompt]
Prompt = %UninsFinal%
Title = %UninsTitle%

[SourceDisksNames.x86]
1="PowerMenu Files","PMenu.cab",,"i386"

[DestinationDirs]
PowerMenu.copy = 16422,"%PowerMenu%"

[SourceDisksFiles]
PowerMenu.exe=1
PowerMenuHook.dll=1
readme.htm=1

[PowerMenu.copy]
PowerMenu.exe
readme.htm
PowerMenuHook.dll

[Start]
HKLM,"%RemoveMe%\PowerMenu","Comments",0,"PowerMenu Visual Enhancement"
HKLM,"%RemoveMe%\PowerMenu","DisplayName",0,"PowerMenu"
HKLM,"%RemoveMe%\PowerMenu","DisplayIcon",0,"%16422%\%PowerMenu%\PowerMenu.exe"
HKLM,"%RemoveMe%\PowerMenu","DisplayVersion",0,"1.5.1"
HKLM,"%RemoveMe%\PowerMenu","NoModify",0x00010001,01,00,00,00
HKLM,"%RemoveMe%\PowerMenu","NoRepair",0x00010001,01,00,00,00
HKLM,"%RemoveMe%\PowerMenu","Publisher",0,"Thong Nguyen"
HKLM,"%RemoveMe%\PowerMenu","UninstallString",0,"rundll32.exe advpack.dll,LaunchINFSection %17%\PowerMenu.inf,uninstall"
HKLM,"SOFTWARE\Microsoft\Windows\CurrentVersion\Run","PowerMenu",0,"%16422%\%PowerMenu%\PowerMenu.exe"

[Strings]
PowerMenu = "Visual+\PowerMenu"
RemoveMe = "SOFTWARE\Microsoft\Windows\CurrentVersion\Uninstall"
UninsTitle = "KelCorp addon uninstaller"
UninsQuest = "Uninstall PowerMenu?"
UninsFinal = "Uninstallation is now completed!."

Posted

Another question: Why do you want to install this during RunOnce when the regular way of integration is better?

BTW removing the [sourceDisksNames.x86] and [sourceDisksFiles] sections will solve the problem

Posted
Another question: Why do you want to install this during RunOnce when the regular way of integration is better?

BTW removing the [sourceDisksNames.x86] and [sourceDisksFiles] sections will solve the problem

I would like to be able to select a few inf addons during the runonce stage of integration using a installer tool. Some inf addons are set up and installed perfectly to my taste as well as they are very customizable. If I could package the inf's into a switchless installer I would, unfortunately I do not possess that knowledge at the time.

I am surprised [sourceDisksFiles] is not needed. I will test and respond.

Thanks Rick

Posted
I would like to be able to select a few inf addons during the runonce stage of integration using a installer tool. Some inf addons are set up and installed perfectly to my taste as well as they are very customizable. If I could package the inf's into a switchless installer I would, unfortunately I do not possess that knowledge at the time.

I am surprised [sourceDisksFiles] is not needed. I will test and respond.

Thanks Rick

Test on running OS completed successfully. Will test install from runonceex.

Posted

The following works if the path to the .inf is true.

rundll32.exe setupapi,InstallHinfSection DefaultInstall 132 C:\<FOLDER>\<FILENAME>.inf

However does anyone have any ideas how to run this code from within a temp folder?

Posted

Yea... This should do it. (not adding C:\PATH)

rundll32 setupapi,InstallHinfSection DefaultInstall 128 setup.inf

If you use WinRAR it can do this ya know, try adding this in your sfx comment

TempMode
setup=setup.inf
Silent=1
Overwrite=1

WinRAR will extract the files to a temp folder and use the defaultinstall section (it should show the progress bar)

Posted
Yea... This should do it. (not adding C:\PATH)

rundll32 setupapi,InstallHinfSection DefaultInstall 128 setup.inf

If you use WinRAR it can do this ya know, try adding this in your sfx comment

TempMode
setup=setup.inf
Silent=1
Overwrite=1

WinRAR will extract the files to a temp folder and use the defaultinstall section (it should show the progress bar)

I forgot about WinRAR! That worked like a charm. I did not test the rundll32 method yet as I accomplished what I was looking for in the WinRAR SFX method. If I try the other method down the road I will post my results.

I really appreciate your help on this ricktendo64.

Join the conversation

You can post now and register later. If you have an account, sign in now to post with your account.

Guest
Reply to this topic...

×   Pasted as rich text.   Paste as plain text instead

  Only 75 emoji are allowed.

×   Your link has been automatically embedded.   Display as a link instead

×   Your previous content has been restored.   Clear editor

×   You cannot paste images directly. Upload or insert images from URL.

×
×
  • Create New...