Innosetup help, please.

Hi,
Could someone knowledgeable please take a look at the Dirs and Files section of my FIRST EVER Innosetup file, and let me know if this script is correct.

I need to Install both my .exe, and the Libs folder, into a folder called Test App inside the Program Files or Program Files(x86), depending on the OS.
I then need to install a folder called Test App Data (containing a database file and a few text files - all of which are read and writeable) into the user’s ApplicationData folder.

Thank you all in advance.
P.S Anyone know what size the personalised Wizard Image and Small Wizard image should be?

[code]; Script generated by the Inno Setup Script Wizard.
; SEE THE DOCUMENTATION FOR DETAILS ON CREATING INNO SETUP SCRIPT FILES!

[Setup]
; NOTE: The value of AppId uniquely identifies this application.
; Do not use the same AppId value in installers for other applications.
; (To generate a new GUID, click Tools | Generate GUID inside the IDE.)
AppId={05829F05-42C5-4BD6-B5F0-306004BF8604}
AppName=Test App
AppVersion=2.0
AppVerName=Test App 2.0
AppPublisher=Joe Bloggs
DefaultDirName={pf}\Test App
DisableDirPage=yes
DefaultGroupName=Test App
DisableProgramGroupPage=yes
OutputDir=C:\Users\me\Desktop
OutputBaseFilename=Test App Setup
Compression=lzma
SolidCompression=yes

[Languages]
Name: “english”; MessagesFile: “compiler:Default.isl”

[Tasks]
Name: “desktopicon”; Description: “{cm:CreateDesktopIcon}”; GroupDescription: “{cm:AdditionalIcons}”; Flags:

; These directories will be created by the installer inside the DefaultDirName (defined above).
[Dirs]
Name: “{app}\Test App Libs”
Name: “{appdata}\Test App Data”

; These are the files to include. By default you want to include the EXE and the Libs folder
; but you can include any other files you like as well.
; Be sure to change the path to point to your built application.

[Files]
Source: “C:\Users\me\Desktop\Test App\Test App.exe”; DestDir: “{app}”; Flags: ignoreversion
Source: “C:\Users\me\Desktop\Test App\Test App Libs\"; DestDir: “{app}\Test App Libs”; Flags: ignoreversion recursesubdirs
Source: "C:\Users\me\Desktop\Test App\Test App Data\
”; DestDir: “{appdata}\Test App Data”; Flags: ignoreversion recursesubdirs createallsubdirs

[Icons]
Name: “{group}\Test App”; Filename: “{app}\Test App.exe”
Name: “{commondesktop}\Test App”; Filename: “{app}\Test App.exe”; Tasks: desktopicon

[Run]
Filename: “{app}\Test App.exe”; Description: “{cm:LaunchProgram,Test App}”; Flags: nowait postinstall skipifsilent[/code]

[quote=79802:@Richard Summers]Hi,
Could someone knowledgeable please take a look at the Dirs and Files section of my FIRST EVER Innosetup file, and let me know if this script is correct.

I need to Install both my .exe, and the Libs folder, into a folder called Test App inside the Program Files or Program Files(x86), depending on the OS.
I then need to install a folder called Test App Data (containing a database file and a few text files - all of which are read and writeable) into the user’s ApplicationData folder.

Thank you all in advance.
P.S Anyone know what size the personalised Wizard Image and Small Wizard image should be?

[code]; Script generated by the Inno Setup Script Wizard.
; SEE THE DOCUMENTATION FOR DETAILS ON CREATING INNO SETUP SCRIPT FILES!

[Setup]
; NOTE: The value of AppId uniquely identifies this application.
; Do not use the same AppId value in installers for other applications.
; (To generate a new GUID, click Tools | Generate GUID inside the IDE.)
AppId={05829F05-42C5-4BD6-B5F0-306004BF8604}
AppName=Test App
AppVersion=2.0
AppVerName=Test App 2.0
AppPublisher=Joe Bloggs
DefaultDirName={pf}\Test App
DisableDirPage=yes
DefaultGroupName=Test App
DisableProgramGroupPage=yes
OutputDir=C:\Users\me\Desktop
OutputBaseFilename=Test App Setup
Compression=lzma
SolidCompression=yes

[Languages]
Name: “english”; MessagesFile: “compiler:Default.isl”

[Tasks]
Name: “desktopicon”; Description: “{cm:CreateDesktopIcon}”; GroupDescription: “{cm:AdditionalIcons}”; Flags:

; These directories will be created by the installer inside the DefaultDirName (defined above).
[Dirs]
Name: “{app}\Test App Libs”
Name: “{appdata}\Test App Data”

; These are the files to include. By default you want to include the EXE and the Libs folder
; but you can include any other files you like as well.
; Be sure to change the path to point to your built application.

[Files]
Source: “C:\Users\me\Desktop\Test App\Test App.exe”; DestDir: “{app}”; Flags: ignoreversion
Source: “C:\Users\me\Desktop\Test App\Test App Libs\"; DestDir: “{app}\Test App Libs”; Flags: ignoreversion recursesubdirs
Source: "C:\Users\me\Desktop\Test App\Test App Data\
”; DestDir: “{appdata}\Test App Data”; Flags: ignoreversion recursesubdirs createallsubdirs

[Icons]
Name: “{group}\Test App”; Filename: “{app}\Test App.exe”
Name: “{commondesktop}\Test App”; Filename: “{app}\Test App.exe”; Tasks: desktopicon

[Run]
Filename: “{app}\Test App.exe”; Description: “{cm:LaunchProgram,Test App}”; Flags: nowait postinstall skipifsilent[/code][/quote]

Wizard image: 164x314 pixels
http://www.jrsoftware.org/ishelp/index.php?topic=setup_wizardimagefile

Wizard Small Image: 55x58 pixels
http://www.jrsoftware.org/ishelp/index.php?topic=setup_wizardimagefile

Here is InnoSetup file I use for one of my apps hoping that it will help you see how another working ISS file was setup.

[Setup]
AppName=Intelligent Subnet Calculator
AppVersion=1.1.11(m)
AppPublisher=Intelligent Visibility, Inc.
AppPublisherURL=http://www.intelligentvisibility.com
DefaultDirName={pf}\Intelligent Subnet Calculator
DefaultGroupName=Intelligent Subnet Calculator
UninstallDisplayIcon={app}\isc-v1.1.11m.exe
Compression=lzma2
SolidCompression=yes
SourceDir=c:\install
WizardImagefile=images\isc-1.bmp
WizardSmallImageFile=images\isc-50x50.bmp

[Files]
Source: “c:\install\isc-v1.1.11m.exe”; DestDir: “{app}”
Source: “c:\install\IntelligentSubnetCalculator Libs\Appearance Pak.dll”; DestDir: “{app}”
Source: “c:\install\IntelligentSubnetCalculator Libs\Crypto.dll”; DestDir: “{app}”
Source: “c:\install\IntelligentSubnetCalculator Libs\GUIKit.dll”; DestDir: “{app}”
Source: “c:\install\IntelligentSubnetCalculator Libs\Internet Encodings.dll”; DestDir: “{app}”
Source: “c:\install\IntelligentSubnetCalculator Libs\msvcp120.dll”; DestDir: “{app}”
Source: “c:\install\IntelligentSubnetCalculator Libs\msvcr120.dll”; DestDir: “{app}”
Source: “c:\install\IntelligentSubnetCalculator Libs\RBGUIFramework.dll”; DestDir: “{app}”
Source: “c:\install\IntelligentSubnetCalculator Libs\RegEx.dll”; DestDir: “{app}”
Source: “c:\install\IntelligentSubnetCalculator Libs\Shell.dll”; DestDir: “{app}”

[Icons]
Name: “{group}\Intelligent Subnet Calculator”; Filename: “{app}\isc-v1.1.11m.exe”

HTH,
Mike

We haven’t really changed it much in years, but I looked through one of our ISS scripts You may want to look at a section for uninstalling:

[UninstallDelete]
Type: filesandordirs; Name: “files you want to uninstall”
Type: filesandordirs; Name: “files you want to uninstall”
Type: filesandordirs; Name: “files you want to uninstall”

Our Setup.bmp is 162x312. I think we downloaded from an INNO support site years ago. Send me a private message with your email address if you want me to send what we use, it is just a standard installer pic. You may want to use something more custom.

Thanks guys.

Merv,
Thank you for the kind offer, but I will create an image tailored specifically to my particular app. I really appreciate the offer though.

The part I am not sure about though, is if my destination paths are correct - in order to save my files into the correct folders.

Your paths look correct. To be sure, of course, you should try it and verify that everything went where you expected.

Thanks Tim.
I can’t at the moment as I am not near a PC, but will eventually.
Just wanted to check in the mean time.

Thank you.

Hi,
I just tried to compile my Innosetup script and the following 3 lines of code all produce practically the same error message.
If I do as the error message suggests and add an extra set of curly brackets - the script compiles but does not create and copy the required files / folders?

Can anyone shed some light?
Thank you.

Code, followed by the error message:

AppId={05829F05-42C5-4BD6-B5F0-306004BF8604}

Compiler Error! Unknown constant "05829F05-42C5-4BD6-B5F0-306004BF8604".Use two consecutive "{" characters if you are trying to embed a single "{" and not a constant.

Code2, followed by the error message:

[Dirs] Name: "{appdata}\\Test App Data"

Compiler Error! Line 31: Unknown constant "appdata".Use two consecutive "{" characters if you are trying to embed a single "{" and not a constant.

Code3, followed by the error message:

[Files] Source: "C:\\Users\\me\\Desktop\\Test App\\Test App Data\\*"; DestDir: "{appdata}\\Test App Data"; Flags: ignoreversion recursesubdirs createallsubdirs

Compiler Error! Line 40: Unknown constant "appdata".Use two consecutive "{" characters if you are trying to embed a single "{" and not a constant.

I think these are your {appdata} choices, see the constants section in the INNO help file:

{localappdata}
The path to the local (nonroaming) Application Data folder.
{userappdata} & {commonappdata}
The path to the Application Data folder.

There is also a good Knowledge Base and FAQ section on the INNO web site: http://www.jrsoftware.org/iskb.php

Merv,
Thank you!

commonappdata did not work either, but userappdata did !

All I need to do now is work out why the first part fails (AppId) ?

We don’t use a generated AppID in our installs. I think it defaults to AppName, so if you make that unique enough shouldn’t be an issue getting mixed up with other programs. I tried yours without the brackets and that seems to work.

Thanks - I will use it without the brackets :slight_smile:

Hi,
My Innosetup installer is now working correctly, but I have noticed that in the same directory as my .exe, there are 2 other files:
unins000 and unins000.dat

I understand that these are related to the uninstall feature, but I do not want an uninstaller at the moment, and would like to be able to prevent these two files from being saved.

Does anyone know if it is possible, and if so, how?

Thank you all in advance.

Do you have access to the INNO Setup Help files? A lot of this stuff is in the there with some examples. I use the uninstaller but, according to the help file it should be:

[Setup]
Uninstallable=no

[quote=80036:@Merv Pate]Do you have access to the INNO Setup Help files? A lot of this stuff is in the there with some examples. I use the uninstaller but, according to the help file it should be:

[Setup]
Uninstallable=no[/quote]

And then you get calls for support because users may rightfully uninstall a program. Especially from the Control Panel. Sounds like a very bad idea.

Thanks Merv,
I had already tried that - to no avail - but I think it may have been a remnant from a previous test install.
I have just deleted EVERYTHING and started all over again, and now it works as expected.

Michel,
Presently, the software is only for me - hence why I said “but I do not want an uninstaller at the moment”.
I agree with you though, and will eventually include this option when required.

Thank you both very much :slight_smile: