Jump to content

Trouble with INF File with sfx/unattended install with options


Lqdwax

Recommended Posts

Hello All:

I have been trying to make a variety of unattended install items. I have been using winrar sfx with .inf files because I want to tailor some of the install options. Below is an install for dvd shrink 3.2 all i want to do is install with no desktop or quick launch icons and I want the "dvdshrink" program folder shortcut to be placed in a newly created folder on the start menu called "DVD VIDEO-AUDIO"(I am not yelling that is just how the folder is named, with all caps).

Below is the .inf

[setup]

Lang=default

Dir=C:\Program Files\DVD Shrink

Group=DVD VIDEO-AUDIO\DVD Shrink

NoIcons=0

Components=

I Then setup winrar SFX and in the comment section i enter this

Setup=dvdshrink32setup.exe /VERYSILENT /LOADINF="dvdshrink32setup.inf"

Silent=1

Overwrite=1

I dont understand I have done this before and I dont know what is wrong this time. I have a bunch of programs with pretty similar options and I cant get them to uninstall. By the way I double checked everything using "Cmenu" This is really driving me crazy. :wacko: As Always the help is Greatly APpreciated.THANKS. thanks.

Link to comment
Share on other sites


I don't quite understand what your problem is. From what I gather, you can't get the programs to install....even though you said uninstall...and you want to see if anyone here can see errors in your WinRAR comments. At least, that is what I am guessing you are asking. It was kind of confusing...

Here are a couple of pointers for your Inno Setup silent install.

1. Be sure you install the program exactly how you want and RECORD the installation. Use "Yourprogram.exe" /SAVEINF="Yourfilename.inf". Don't write your own .inf, as programs have different values that go in the .inf file.

2. Make sure you have the full path to "Yourfilename.inf". When zipped inside a WinRAR SFX, I usually specify the unzip directory as %temp%, and for the Setup line I then put Setup="Yourprogram.exe" /LOADINF="%temp%\Yourfilename.inf". You have to make sure the installer can find your .inf file.

3. Sometimes programmers use certain install packages (like Inno), but then don't bother to program in the "/SAVEINF=" option. So again, make sure your install actually writes its own .inf file with the "/SAVEINF=" switch.

You can also read up more about this type of installer here.

If you want better answers, give a better explanation of what exactly your problem is.

Hope this helps.

--radigast

Edited by radigast
Link to comment
Share on other sites

The path to your INF may be the problem, by default Windows will look in %WinDir%\inf.

Try removing the quotes and using this path .\

Setup=dvdshrink32setup.exe /VERYSILENT /LOADINF=.\dvdshrink32setup.inf
Silent=1
Overwrite=1

Link to comment
Share on other sites

Radigast,

Thanks for the tips and sorry if my question was unclear so i will restate. I am using cmenu hXXp://www.msfn.org/board/CMenu-t47645.html&hl=cmenu

The Process is:

First.

I use cmenu to identify installer and then i record the install. say for example "DVD FAB HD decrypter"it then spits out the inf file.

[setup]

Lang=English

Dir=C:\Program Files\DVDFab HD Decrypter 4

Group="DVD VIDEO-AUDIO\DVDFab HD Decrypter"

NoIcons=0

Tasks=

Second.

I take inf file and exe and create a winrar sfx. in the comment section I input:

Setup=DVDFabHDDecrypter4012.exe /VERYSILENT /LOADINF=.\DVDFabHDDecrypter4012.inf

Path=%userprofile%\Local Settings\Temp

SavePath

Silent=1

Overwrite=1

and finally zip it up and install it.

now here is the problem. In the inf under group. I have it set to install under a custom group heading and it is not working. the program silently installs fine. but none of the custom settings in the inf are getting installed correctly. no specialized group that i specified in the inf. the "NoIcons" command is not working either because i have it set to not install any icons and it does.

In my opinion i dont think it is following the inf file. i followed what "ricktendo64" said in the post after your post. what ricktendo64 said worked for dvd shrink but it is not working for dvdfab.

I am really puzzled by all of this and maybe i am being to long winded. but i am trying to explain the best i can. THANKS tons for all the help now and in advance.

Link to comment
Share on other sites

In my opinion i dont think it is following the inf file.

I can't specifically say for DVDFab since I have never installed/used the program, but from my experience, some programs do NOT follow the .inf file. The programmers forgot/did not want to/started smoking crack while they were coding the installer, and just forgot to include certain switch support in the installer.

When I have run into this problem of not reading all my custom settings from the .inf file, I do the normal silent install. Then I look to see what shortcuts the program installed that I didn't want, and use a .cmd / .bat file to clean up/move/rename the shortcuts. Once you get the .cmd / .bat file made (yes, you do have to code that yourself), just package that file inside your WinRAR sfx. Then, under the comment section of WinRAR, just add another "setup=" path to your .cmd / .bat file.

For example:

Setup="MyProgram.exe /switch /switch"

Setup="MyCleanup.cmd"

Then, your program will autoinstall, and your cleanup file will customize that install for you!

If you are not sure about batch files, then search the forums. There is a ton of info. on here about them! Here is a starter link.

Some common environment variables you will use in your batch files when moving/deleting shortcuts are:

1. All users start menu: "%allusersprofile%\Start Menu"

2. Individual users start menu: "%userprofile%\Start Menu"

3. All users dekstop: "%allusersprofile%\Desktop"

4. Individual users desktop: "%userprofile%\Desktop"

5. Quicklaunch:"%userprofile%\Application Data\Microsoft\Internet Explorer\Quick Launch"

Hopefully that gets you started!

--radigast

FYI: A path of "%userprofile%\Local Settings\Temp" is the same as "%temp%"

Link to comment
Share on other sites

In my opinion i dont think it is following the inf file.

I can't specifically say for DVDFab since I have never installed/used the program, but from my experience, some programs do NOT follow the .inf file. The programmers forgot/did not want to/started smoking crack while they were coding the installer, and just forgot to include certain switch support in the installer.

When I have run into this problem of not reading all my custom settings from the .inf file, I do the normal silent install. Then I look to see what shortcuts the program installed that I didn't want, and use a .cmd / .bat file to clean up/move/rename the shortcuts. Once you get the .cmd / .bat file made (yes, you do have to code that yourself), just package that file inside your WinRAR sfx. Then, under the comment section of WinRAR, just add another "setup=" path to your .cmd / .bat file.

For example:

Setup="MyProgram.exe /switch /switch"

Setup="MyCleanup.cmd"

Then, your program will autoinstall, and your cleanup file will customize that install for you!

If you are not sure about batch files, then search the forums. There is a ton of info. on here about them! Here is a starter link.

Some common environment variables you will use in your batch files when moving/deleting shortcuts are:

1. All users start menu: "%allusersprofile%\Start Menu"

2. Individual users start menu: "%userprofile%\Start Menu"

3. All users dekstop: "%allusersprofile%\Desktop"

4. Individual users desktop: "%userprofile%\Desktop"

5. Quicklaunch:"%userprofile%\Application Data\Microsoft\Internet Explorer\Quick Launch"

Hopefully that gets you started!

--radigast

FYI: A path of "%userprofile%\Local Settings\Temp" is the same as "%temp%"

Radigast,

First thanks for the response. secondly, I am familiar with bat/cmd files. I tried your method but the batch file is being run to fast. I mean before the initial program is finished being setup the batch file is running. could you please be a little more specific in what you are saying for i am very eager to learn this method as it will help me out a lot. THANKS

Link to comment
Share on other sites

You can use sleep.exe and call it in you cmd like this: sleep 15 (time to wait before continuing, in seconds).

However, there are many sleep.exe on the internet. Try searching this forum, there are posts that me or other users made using this file.

If you find another, place in your System32 folder so you can call it without any path.

Also, search for cmdow.exe, which is useful becaue it totally hides command windows. Call it like this: cmdow @ /HID at the top of your cmd file.

Place both on $OEM$/$$/System32. You can read about it in the Unattended Guide.

Here is an example of a cleanup.cmd i use for WinXP.

xcopy "%AllUsersProfile%\Men£ Inicio\Programas\DVD Shrink\DVD Shrink 3.2.lnk" "%AllUsersProfile%\Men£ Inicio\Programas\DVD Tools\" /Y /Q

RD /S /Q "%AllUsersProfile%\Men£ Inicio\Programas\DVD Shrink\"

DEL /f /q "%UserProfile%\Men£ Inicio\Programas\DVD Shrink 3.2.lnk"

The first line copies the shortcut and the second and third delete the original file and the folder in the start menu.

Link to comment
Share on other sites

  • 3 months later...

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...