Jump to content

noob question. need some help


Recommended Posts

I´m studying .inf files now, ´cause i´m believing they are more efficient and powerfull than batch and reg files.

They will take my unattended install to another level, or at least i beleive so.

I got this idead by reading some gosh´s topics and his site.

So need some advices from experts in inf files.

What are the sections i can use on inf files?

I´m seeing there are many of them, like [DefaultInstall], [Add.Settings], [keys], [post.delete], [wmp9], [folder_Options], [inetOptions], [Reduce.Reg] and many others.

Everything inside [ ] are some kind of variables that are recognized by windows when the inf is installed, or is the user that defines them?

I noticed that anything you put bellow the [DefaulInstall] is a subsection that you can name anything you want, creating a subcategorie.

But for the subcategorie to work, it has to be related on the [DefaulInstall] Section with a recognizable variable, like DelReg = RegEntriesDeleted, or other name i want, but the DelReg is the word i can´t change.

What are the other functions, like DelReg, that i can use?

If they are some kind of variable, where can i find a complete list of them so i can see what exactly can i do with inf files?

I already see that i can replace my entire RunOnceEx batch file with an simple inf file, and that sounds very interesting.

I also see that gosh made 4 inf files with different stuff inside of them, each one with a different purpose.

That´s what i plan to do: One to install my apps, other for tweaks, other for drivers, and so on...

But how do i call the inf file in my xp setup?

Is it throught GuiRunOnce?

I´m just starting here. If someone could give me a detailed explanation about using INF files or links where i can learn it, i´d really appreciate it.

Link to comment
Share on other sites


This is my CDLMROEX.INF! It resides as I:\$OEM$\CDLMROEX.INF along with I:\$OEM$\UserAdd.cmd!

Where I: is a CD-ROM letter.

CDLMROEX.INF is called by UserAdd.cmd using this line of code:

START /WAIT rundll32 %SystemRoot%\system32\ADVPACK.DLL,LaunchINFSection CDLMROEX.inf,DefaultInstall

I use CDLMROEX.INF instead of RunOnceEx.cmd. The included apps are to be installed right from a CD.

So, %01% resolves to I:\$OEM$ where CDLMROEX.INF resides. (see the code, below!)

As you may have already guessed, whenever %01% is used in an INF file;

it always resolves to the path where the INF resides.

NB: CDLMROEX, you see in %01%\CDLMROEX, is the folder containing apps to be installed.

It has no relation to the INF name!

However, there are variables other than %01%.

For a complete list and intensive information on INF files, you should use WillyPad;

freeware by Snoopy81.

[Version]
Signature = $CHICAGO$

[DefaultInstall]
AddReg = AddReg.LMROEXCD

[AddReg.LMROEXCD]
HKLM,%LMROEX%,"TITLE",,"Hi Bingo! - CD LM ROEX"
HKLM,%LMROEX%\001,,,"ResEdit 2.200010"
HKLM,%LMROEX%\001,"1",,"%01%\CDLMROEX\ResEdit\ResEdit.msi /qn"
HKLM,%LMROEX%\002,,,"Calculator Plus 1.0"
HKLM,%LMROEX%\002,"1",,"%01%\CDLMROEX\CalcPlus\CalcPlus.msi /qn"
HKLM,%LMROEX%\003,,,"GetDiz 3.0"
HKLM,%LMROEX%\003,"1",,"%01%\CDLMROEX\GetDiz\GetDiz.msi /qn"
HKLM,%LMROEX%\004,,,"Opera 9.01 - Just a sec. Browser!"
HKLM,%LMROEX%\004,"1",,"%01%\CDLMROEX\Opera901\Opera901.msi /passive CREATE_DESKTOP_ICON=0 CREATE_QUICKLAUNCH_ICON=1 CREATE_STARTMENU_ICONS=1 MULTI_USER_SETTING=0 INSTALLER_LANGUAGE=en"
HKLM,%LMROEX%\005,,,"Install Tailor 6"
HKLM,%LMROEX%\005,"1",,"%01%\CDLMROEX\ITailor6\ITailor6.msi /qn"
HKLM,%LMROEX%\006,,,"TweakUI 2.10"
HKLM,%LMROEX%\006,"1",,"%01%\CDLMROEX\TWEAKUI\TweakUI.msi /qn"
HKLM,%LMROEX%\007,,,"Snoqualmie 1.0 Plus"
HKLM,%LMROEX%\007,"1",,"%01%\CDLMROEX\KaleSnoq\KaleSnoq.msi /qn"
HKLM,%LMROEX%\008,,,"MSN Messenger 7.5"
HKLM,%LMROEX%\008,"1",,"%01%\CDLMROEX\MSN75\MSN75.msi /qn"
HKLM,%LMROEX%\008,"2",,"REGEDIT /S %01%\CDLMROEX\MSN75\MSN75.reg"
HKLM,%LMROEX%\009,,,"TuneUp Utilities 2006 5.0.2331"
HKLM,%LMROEX%\009,"1",,"%01%\CDLMROEX\TU2006\TU2006.msi /qn"
HKLM,%LMROEX%\009,"2",,"REGEDIT /S %01%\CDLMROEX\TU2006\TU2006.reg"
HKLM,%LMROEX%\010,,,"WinDriver Ghost E 2.01"
HKLM,%LMROEX%\010,"1",,"%01%\CDLMROEX\WinDrivr\WinDrivr.exe /s"
HKLM,%LMROEX%\010,"2",,"%01%\CDLMROEX\WinDrivr\WinDrivr.js"
HKLM,%LMROEX%\011,,,"ImgBurn 2.1.0.0"
HKLM,%LMROEX%\011,"1",,"%01%\CDLMROEX\ImgBurn\ImgBurn.js"
HKLM,%LMROEX%\011,"2",,"REGEDIT /S %01%\CDLMROEX\ImgBurn\ImgBurn.reg"
HKLM,%LMROEX%\012,,,"SAV CE 9.0.0.1400"
HKLM,%LMROEX%\012,"1",,"%01%\CDLMROEX\SAV91400\SAV91400.exe"
HKLM,%LMROEX%\013,,,"Symantec LiveUpdate 3.1"
HKLM,%LMROEX%\013,"1",,"%01%\CDLMROEX\SAV91400\LU31.exe"
HKLM,%LMROEX%\013,"2",,"REGEDIT /S %01%\CDLMROEX\SAV91400\SAV91400.reg"
HKLM,%LMROEX%\099,,,"LM Tweaks"
HKLM,%LMROEX%\099,"1",,"REGEDIT /S %01%\CDLMROEX\Utils\ExplorLM.reg"
HKLM,%LMROEX%\099,"2",,"REGEDIT /S %01%\CDLMROEX\Utils\ieLM.reg"
HKLM,%LMROEX%\099,"3",,"REGEDIT /S %01%\CDLMROEX\Utils\TweakLM.reg"
HKLM,%LMROEX%\100,,,"Adding cleanup.cmd to LMRO"
HKLM,%LMROEX%\100,"1",,"REG ADD %LMRO% /v CLEANUP /d %10%\HDCURO\CleanUP.cmd"

[STRINGS]
LMROEX="SOFTWARE\Microsoft\Windows\CurrentVersion\RunOnceEx"
LMRO="HKLM\SOFTWARE\Microsoft\Windows\CurrentVersion\RunOnce"

Edited by mazin
Link to comment
Share on other sites

mazin, you again helping me.

alright, i made my runonceex.inf, services.inf and tweaks.inf

now how do i call those files?

through cmdlines?

what is the command to call my runonceex.inf?

and i need the command to call services.inf and tweaks.inf from the runonceex.inf file.

how do i do it?

Link to comment
Share on other sites

[Add.Settings], [keys], [post.delete], [wmp9], [folder_Options], [inetOptions], [Reduce.Reg]
These are not varialbles, theyare either CopyFiles or AddReg sections

So under [DefaultInstall] you might see

CopyFiles = wmp9

AddReg = Add.Settings, Folder_Options

DelReg = Reduce.Reg

Link to comment
Share on other sites

now how do i call those files?

through cmdlines?

Honestly, I don't call them from cmdlines.txt directly!

This is my cmdlines.txt:

[COMMANDS]"UserAdd.cmd"

This is my UserAdd.cmd:

@echo off

Title Creating A User Account...

ECHO.

ECHO.

ECHO -- Please wait...

START /WAIT rundll32 %SystemRoot%\system32\ADVPACK.DLL,LaunchINFSection CDLMROEX.inf,DefaultInstall

START /WAIT rundll32 %SystemRoot%\system32\ADVPACK.DLL,LaunchINFSection HDCURO.inf,DefaultInstall

cls

All cmdlines.txt, UserAdd.cmd, CDLMROEX.inf, and HDCURO.inf are in $OEM$ folder.

Link to comment
Share on other sites

the problem is that my runonceex file has many of the "rundll32.exe iernonce.dll,RunOnceExProcess" lines, witch causes RunOnceEx to open at the exact moment it is called (at least in batch files it works like this).

wouldn´t it be better, in this case, if i call the inf files through GuiRunOnce?

and seconde question, mazin. lets say a have this tweaks in a reg file:

; Disable all Balloon Tips

[HKEY_CURRENT_USER\Software\Microsoft\Windows\CurrentVersion\Explorer\Advanced]

"EnableBalloonTips"=dword:00000000

"FolderContentsInfoTip"=dword:00000000

"ShowInfoTip"=dword:00000000

"StartButtonBalloonTip"=dword:00000000

"NoSMBalloonTip"=dword:00000000

It has many values in only one path in the registry...

how would it be converted to INF?

I was guessing it would be like:

HKCU\Software\Microsoft\Windows\CurrentVersion\Explorer\Advanced,EnableBallonTips,0x00010001,0

HKCU\Software\Microsoft\Windows\CurrentVersion\Explorer\Advanced,FolderContentsInfoTip,0x00010001,0

and goes on. is this correct?

and last question: the [DefaultInstall] section works when i rightclick the file and click Install, then all the things under this section will be installed, right? but what if i just want to install a particular section of the inf file that i made myself, lets say, [Reg.Tweaks]. How do i call that particular section?

and rickntendo, i get it now, but where do i get the full list of these main funcions to use, like DelReg, AddReg, all those that are the main function that an inf file can do?

again, thanks both for your help.

Edited by gugutz
Link to comment
Share on other sites

HKCU,Software\Microsoft\Windows\CurrentVersion\Explorer\Advanced,EnableBalloonTips,0x10001,0
HKCU,Software\Microsoft\Windows\CurrentVersion\Explorer\Advanced,FolderContentsInfoTip,0x10001,0
HKCU,Software\Microsoft\Windows\CurrentVersion\Explorer\Advanced,ShowInfoTip,0x10001,0
HKCU,Software\Microsoft\Windows\CurrentVersion\Explorer\Advanced,StartButtonBalloonTip,0x10001,0
HKCU,Software\Microsoft\Windows\CurrentVersion\Explorer\Advanced,NoSMBalloonTip,0x10001,0

or better practice:

HKCU,%VAR%,EnableBalloonTips,0x10001,0
HKCU,%VAR%,FolderContentsInfoTip,0x10001,0
HKCU,%VAR%,ShowInfoTip,0x10001,0
HKCU,%VAR%,StartButtonBalloonTip,0x10001,0
HKCU,%VAR%,NoSMBalloonTip,0x10001,0

[Strings]
VAR="Software\Microsoft\Windows\CurrentVersion\Explorer\Advanced"

<Edit>

Also for your non-DefaultInstall section

cmdlines.txt

[Commands]
"rundll32.exe advpack,LaunchINFSection .\myinf.inf, SectionName"

or

cmdlines.txt

[Commands]
"rundll32.exe setupapi,InstallHinfSection SectionName 128 .\myinf.inf"

</Edit>

Link to comment
Share on other sites

thanks, Yzöwl.

but what is the difference between the two commands?

why "rundll32.exe advpack,LaunchINFSection .\myinf.inf, SectionName" uses "advpack" and in "rundll32.exe setupapi,InstallHinfSection SectionName 128 .\myinf.inf" it uses "setupapi" and this "128" number?

Are there any vantages or disvantages of using one or other?

and about calling the inf file from cmdlines.txt: my runonceex file installs too many progs, so i have to open new windows of RunOnceEx with the rundll32.exe iernonce.dll,RunOnceExProcess command.

When i used batch files to install apps via RunOnceEx, if i called RoE through cmdlines.txt, because my batch file contains that line, it caused the RunOnceEx windows to be launched right at T-12 of setup part, witch is when cmdlines.txt is executed. That´s why i have to begin to use the GuiRunOnce method to use my RunOnceEx.cmd.

Won´t this happen as well if i use cmdlines to call my inf file, since my runonceex.inf will still have rundll32.exe iernonce.dll,RunOnceExProcess lines to open new windows to installing apps and finishing the configuration?

and to conclude: to call from runonceex.inf my other inf files, the procedure is the same? i mean:

HKLM,%LMROEX%\050,,,"Configuring Services"
HKLM,%LMROEX%\012,"1",,"%01%\rundll32.exe advpack,LaunchINFSection %Systemdrive%\apps\services.inf, DefaultInstall"

would it be like this?

Link to comment
Share on other sites

no one knows the answer to the above questions?

and i have some more :blushing:

i´m converting my regtweaks collection from reg to inf.

so there is values in the registry that have to be added, and other have to be deleted.

In a inf file, i can delete registry entrie with the "DelReg" function. But in only one inf file, there will be tweaks for various types of things. Example: in my Internet-Networking.inf, there will be the [56k], [DSL], [Cable] and [LocalNetwork] subcategories. If i place some DelReg funcions under and related to each one of these main subcategories, won´t the inf confuse things out and, when i call a specific section of the inf file, like [56K], won´t it call the DelReg functions that are under the other categories too, like the one under [DSL]?

if yes, then how do i solve this? isn´t there another way to exclude values in the registry different than DelReg?

´cause if there isn´t. then i´ll have to make a different inf file for each type of tweak, witch would break the purpose of using inf files for me.

Link to comment
Share on other sites

Create an account or sign in to comment

You need to be a member in order to leave a comment

Create an account

Sign up for a new account in our community. It's easy!

Register a new account

Sign in

Already have an account? Sign in here.

Sign In Now
  • Recently Browsing   0 members

    • No registered users viewing this page.
×
×
  • Create New...