|
Hello,
Your installer is awesome but after some testing I found a few issues.
The most important is that there is no error message when dotnetfx fails to install (for example it does that when you have too old IE). In that case installer should cancel with error message.
The next issues are:
a) .NET 2.0 requires IE 5.0.5, however IE6 is installed, so i changed
RegQueryStringValue(HKLM, 'Software\Microsoft\Internet Explorer', 'Version', SoftwareVersion);
if (SoftwareVersion < '5') then begin
to
RegQueryStringValue(HKLM, 'Software\Microsoft\Internet Explorer', 'Version', SoftwareVersion);
if (SoftwareVersion <= '5') then begin
b)
Filename: "{ini:{tmp}\dep.ini,install,dotnet}"; Description: "{cm:DOTNETTitle}"; StatusMsg: "{cm:DOTNETInstallMsg}"; Parameters: "/Q /c:""install /q"""; Flags: skipifdoesntexist
Due to installer error (invalid param) I needed to change /C param to lowercase
|
|
|
|
|
Thanks- great script. I hadn't even heard of InnoSetup until I read this and was struggling to get a Vs.net Setup Project to do what I wanted. Within a day I have the setup complete and installing the .Net Framework as required. Thanks.
|
|
|
|
|
hello
i have a app that use .net fx 3.0
how can I create a .net fx v3.0 checker .
|
|
|
|
|
|
is there any chance that there will
be a option to install .net 2.0 sp1 IF
.net 2.0 isnt installed..
can jump start you with the parameters :P
"/q /norestart" - Silent
"/qb /norestart" - Progressbar (MSi style)
there are some minor differences with sp1
like 2.0 req: 2000 sp3 while sp1 req 2000 sp4..
Make my wishes come true!
|
|
|
|
|
Hello,
sorry - again: The path for the needed prerequesites is not found under Windows ME (but on Vista, XP and Win2k). I can not see why the path for the prerequesites are handled different on Windwos ME.
I do not know how to debug this new version with the three files.
Meanwhile my installation on Windows ME fails... Hopefully you can provide a sulution!
Best regards
udk
udk
|
|
|
|
|
Hello,
I tried the .NET Framework Installer on Windows 2000 there it works fine. Then the same Installer does not find the prerequesites on the CD (Both OS were without .NET Framework 2.0).
Any suggestions (I tried lowercase but this did not change this behavior).
Best regards
udk
udk
|
|
|
|
|
Message Closed
modified 23-Dec-20 12:46pm.
|
|
|
|
|
Sorry for confusing!
Setup does not find the prerequesits installing under Windows ME. It always trys to download them. In the last Setup window showing the things to be done the needed prerequesites like below:
Download dependencies:
Microsoft .NET Framework 2.0
Microsoft .NET Framework 2.0 Sprachpaket Deutsch
Install dependencies:
Microsoft .NET Framework 2.0
Microsoft .NET Framework 2.0 Sprachpaket Deutsch
Under Windows 2000 the dependencies location on the CD is recognized and no download is initiated:
Install dependencies:
Windows Installer 3.1
Microsoft .NET Framework 2.0
The settings done in dotnet20_strings.iss are
DependenciesDir=Microsoft
All prerequesites are stored in the path "Microsoft"
udk
udk
|
|
|
|
|
Hätte ich es gewusst, dann hätte ich mir zwei Wochen arbeit sparen können!
Ist viel besser geworden als meine Version. Tausend Dank!
Gruß
udk
udk
|
|
|
|
|
Message Removed
modified 5-Aug-20 6:18am.
|
|
|
|
|
Hi,
First, this is one great tool. Thumbs up. Well, I have an issue I hope you can help me with. I ship MDF files with my application which need SQL server 2005 express as a prerequisite. Can the script be used as is or edited to work with this prerequisite?!
Thanks
|
|
|
|
|
|
It would probably be a good idea to use that article, if the SOFTWARE\Microsoft\NET Framework Setup\NDP\* keys aren't safe. I haven't run into problem with them myself, but that doesn't mean they don't have any.
A problem for me is, that I have made my own .Net (and other apps) detector / downloader / installer, which works for the whole .Net family, and the HKEY_LOCAL_MACHINE\SOFTWARE\Microsoft\.NETFramework\policy\* keys described in the article you refer to, don't support .Net 3.0, .Net 3.0 SP1 or .Net 3.5, but the SOFTWARE\Microsoft\NET Framework Setup\NDP\* keys do...
What to do about those...
I'm in the high-fidelity first class traveling set.
And I think I need a Lear jet.
|
|
|
|
|
I also have the same problem(intsalled and then uninstalled on same machine and still the "Policy" kys exists). Even in the post I saw the same keys!!
which other keys you mean to say for this problem.
|
|
|
|
|
First thank you for this great setup script.
I would need also a version for a .NET Framework 3.5 application. How can I check on .NET 3.5?
This should be probably even easier, because .NET Framework 3.5 seems to work only on Windows XP/Vista/2003/2008. Therefore there should not be that many dependencies anymore. Does someone has an idea on that?
Thank you very much in advance
Andreas
http://www.ab-tools.com/English/[^]
|
|
|
|
|
First of all - thanks for a great Inno add-on!
I seem to miss a language translation possibility, for the download Window. I guess you make that window in your isxdl.dll, so I don't know how much work it would be, to make that window translateable. It just looks silly, when all the other windows i my installer is in danish, and then this one download window is in english.
Could you please include .Net 2.0 SP1 also? My .Net 2.0 application requires it you see
Link to .Net 2.0 SP1
Is your isxdl.dll secret, or could I have the sourcecode, so I could make the additions myself?
I'm in the high-fidelity first class traveling set.
And I think I need a Lear jet.
|
|
|
|
|
Nevermind on the SP1 question. I found out how to do it via the provided script code. Actually made myself a .Net 3.5 version which runs like a dream
I still have the language issue in the download window though.
I'm in the high-fidelity first class traveling set.
And I think I need a Lear jet.
|
|
|
|
|
Hello spif2001,
I saw you've wrote that you've made a .NET 3.5 version.
That would be exactly what I'd need for my application, too.
It would be really great if you could post your code changes done for using it with .NET 3.5.
Thank you very much in advance
Andreas
http://www.ab-tools.com/English/[^]
|
|
|
|
|
Sure - but I have moved a lot of things around. Hope you can figure it out.
I have made it so, that any new application installer I make, have to have some ekstra includes. Heres an example of a Test Installer's main iss file:
#define ApplicationName "DotNetTest"
#include "C:\Inno Installers\Common Inno Files\CustomLanguage\CustomLanguage.iss"
#include "C:\Inno Installers\Common Inno Files\ISXDL\isxdl.iss"
#include "C:\Inno Installers\Common Inno Files\Defines\Defines.iss"
#include "C:\Inno Installers\Common Inno Files\DotNet 3.5\DotNet35.iss"
[Setup]
AppName=TestDotNet35
AppVerName=TestDotNet35 v1.0
DefaultDirName=C:\TestDotNet35
DefaultGroupName=TestDotNet35
OutputBaseFilename=TestDotNet35 v1.0
OutputDir=C:\Inno Installers\Test installers\Compiled tests
Compression=lzma
SolidCompression=yes
PrivilegesRequired=admin
[Files]
Source: C:\some.exe; DestDir: {app};
[UninstallDelete]
Type: filesandordirs; Name: {app}
I have a rather large hierarchy of iss files, because I love to reuse code.
Just as in this article's installer, I include the ISXDL.iss file.
All language specific messages I have in a CustomLanguage.iss file which looks like this:
#include "C:\Inno Installers\Common Inno Files\CustomLanguage\English\CustomEnglish.iss"
#include "C:\Inno Installers\Common Inno Files\CustomLanguage\German\CustomGerman.iss"
#include "C:\Inno Installers\Common Inno Files\CustomLanguage\Danish\CustomDanish.iss"
#include "C:\Inno Installers\Common Inno Files\CustomLanguage\Swedish\CustomSwedish.iss"
[Languages]
;Name: english; MessagesFile: compiler:Default.isl; LicenseFile: C:\Inno Installers\Common Inno Files\CustomLanguage\English\{#ApplicationName} license\English.txt
;Name: german; MessagesFile: compiler:Languages\German.isl; LicenseFile: C:\Inno Installers\Common Inno Files\CustomLanguage\German\{#ApplicationName} license\German.txt
;Name: danish; MessagesFile: compiler:Languages\Danish.isl; LicenseFile: C:\Inno Installers\Common Inno Files\CustomLanguage\Danish\{#ApplicationName} license\Danish.txt
;Name: swedish; MessagesFile: compiler:Languages\Swedish.isl; LicenseFile: C:\Inno Installers\Common Inno Files\CustomLanguage\Swedish\{#ApplicationName} license\Swedish.txt
Name: english; MessagesFile: compiler:Default.isl; LicenseFile: C:\Inno Installers\Common Inno Files\CustomLanguage\English\General License.rtf
Name: german; MessagesFile: compiler:Languages\German.isl; LicenseFile: C:\Inno Installers\Common Inno Files\CustomLanguage\German\General License.rtf
Name: danish; MessagesFile: compiler:Languages\Danish.isl; LicenseFile: C:\Inno Installers\Common Inno Files\CustomLanguage\Danish\General License.rtf
Name: swedish; MessagesFile: compiler:Languages\Swedish.isl; LicenseFile: C:\Inno Installers\Common Inno Files\CustomLanguage\Swedish\General License.rtf
[CustomMessages]
DependenciesDir=Prerequisites
MSI20Title=Windows Installer 2.0
MSI31Title=Windows Installer 3.1
IE6Title=Internet Explorer 6
MDACTitle=MDAC 2.8
DOTNET20Title=Microsoft .NET Framework 2.0
DOTNET20SP1Title=Microsoft .NET Framework 2.0 Service Pack 1
DOTNET35Title=Microsoft .NET Framework 3.5
SqlExpress2005SP2Title=Microsoft SQL Server 2005 Express Edition Service Pack 2
Sql2005XMOTitle=Microsoft SQL Server 2005 Management Objects Collection
This language file includes country specific language iss files, where the english version looks like this:
[CustomMessages]
english.Install_CloseRunningProgram=An instance of {#ApplicationName} is already running. Please close the running {#ApplicationName} application and run {#ApplicationName} Setup again.
english.Uninstall_CloseRunningProgram=An instance of {#ApplicationName} is running. Please close the running {#ApplicationName} application and try uninstalling {#ApplicationName} again.
english.OldUninstall_1={#ApplicationName} Setup found an old {#ApplicationName} program on the system, which MUST be removed before this installation can continue.
english.OldUninstall_2=Do you wish to remove this old {#ApplicationName} program now?
english.OldUninstallFail=Could not uninstall the old {#ApplicationName} installation! Please uninstall {#ApplicationName} via Add/Remove programs in the Control Panel.
english.InstallFor=Install {#ApplicationName} for:
english.Everyone=Everyone
english.JustMe=Just me
english.DependenciesDownloadTitle=Download Dependencies
english.DependenciesInstallTitle=Install Dependencies
english.Win2000Sp3Msg=Windows 2000 Service Pack 3 must be installed before {#ApplicationName} Setup can continue. Please install Windows 2000 Service Pack 3 and run {#ApplicationName} Setup again.
english.WinXPSp2Msg=Windows XP Service Pack 2 must be installed before {#ApplicationName} Setup can continue. Please install Windows XP Service Pack 2 and run {#ApplicationName} Setup again.
english.SqlExpressSP2Msg={#ApplicationName} Setup could not find a Microsoft SQL Server on the computer.%n%nDo you wish to install Microsoft SQL Server 2005 Express Edition Service Pack 2 during the {#ApplicationName} installation?
english.DownloadMsg1=The following applications are required before {#ApplicationName} Setup can continue:
english.DownloadMsg2=Download and install now?
english.SqlExpress2005SP2DownloadSize=~37.5 MB
english.Sql2005XMODownloadSize=~9.2 MB
english.MSI20DownloadSize=~1.7 MB
english.MSI31DownloadSize=~2.5 MB
english.IE6DownloadSize=~46 MB
english.MDACDownloadSize=~5.4 MB
english.DOTNET20DownloadSize=~23 MB
english.DOTNET20SP1DownloadSize=~23.5 MB
english.DOTNET35DownloadSize=~200 MB
english.SqlExpress2005SP2InstallMsg=Installing Microsoft SQL Server 2005 Express Edition Service Pack 2... (May take a few minutes)
english.Sql2005XMOInstallMsg=Installing Microsoft SQL Server 2005 Management Objects Collection... (May take a few minutes)
english.MSI20InstallMsg=Installing Windows Installer 2.0... (May take a few minutes)
english.MSI31InstallMsg=Installing Windows Installer 3.1... (May take a few minutes)
english.IE6InstallMsg=Installing Internet Explorer 6... (May take a few minutes)
english.DOTNET20InstallMsg=Installing Microsoft .NET Framework 2.0... (May take a few minutes)
english.DOTNET20SP1InstallMsg=Installing Microsoft .NET Framework 2.0 Service Pack 1... (May take a few minutes)
english.DOTNET35InstallMsg=Installing Microsoft .NET Framework 3.5... (May take a few minutes)
I also have a defines.iss file with my URL's in looking like this
#define MSI20URL "'http://download.microsoft.com/download/WindowsInstaller/Install/2.0/W9XMe/EN-US/InstMsiA.exe'"
#define MSI31URL "'http://download.microsoft.com/download/1/4/7/147ded26-931c-4daf-9095-ec7baf996f46/WindowsInstaller-KB893803-v2-x86.exe'"
#define IE6URL "'http://download.microsoft.com/download/ie6sp1/finrel/6_sp1/W98NT42KMeXP/EN-US/ie6setup.exe'"
#define DotNet11URL "'http://download.microsoft.com/download/a/a/c/aac39226-8825-44ce-90e3-bf8203e74006/dotnetfx.exe'"
#define DotNet20URL "'http://download.microsoft.com/download/5/6/7/567758a3-759e-473e-bf8f-52154438565a/dotnetfx.exe'"
#define DotNet20SP1URL "'***Placed on local server***'"
#define DotNet35URL "'http://download.microsoft.com/download/6/0/f/60fc5854-3cb8-4892-b6db-bd4f42510f28/dotnetfx35.exe'"
#define SQLExpress2005SP2URL "'http://go.microsoft.com/fwlink/?LinkId=65212'"
#define SQL2005XMOURL "'http://download.microsoft.com/download/4/4/D/44DBDE61-B385-4FC2-A67D-48053B8F9FAD/SQLServer2005_XMO.msi'"
...and finally the dotnet35.iss file which was your primary interest:
[Run]
Filename: {ini:{tmp}\dep.ini,install,msi31}; Description: {cm:MSI31Title}; StatusMsg: {cm:MSI31InstallMsg}; Parameters: "/quiet"; Flags: skipifdoesntexist
Filename: {ini:{tmp}\dep.ini,install,dotnet35}; Description: {cm:DOTNET35Title}; StatusMsg: {cm:DOTNET35InstallMsg}; Parameters: "/Q /T:{tmp}\dotnetfx35 /C:""install /qb"""; Flags: skipifdoesntexist
[Code]
var
dotnet35Path, msi31Path, neededDependenciesDownloadMemo, neededDependenciesInstallMemo, neededDependenciesDownloadMsg: string;
downloadNeeded: boolean;
procedure DecodeVersion(const Version: cardinal; var a, b : word);
begin
a := word(Version shr 16);
b := word(Version and not $ffff0000);
end;
function IsMinMSIAvailable(HV:Integer; NV:Integer ): boolean;
var
Version, dummy : cardinal;
MsiHiVer, MsiLoVer : word;
begin
Result:=(FileExists(ExpandConstant('{sys}\msi.dll'))) and (GetVersionNumbers(ExpandConstant('{sys}\msi.dll'), Version, dummy));
DecodeVersion(Version, MsiHiVer, MsiLoVer);
Result:= (Result) and (MsiHiVer >= HV) and (MsiLoVer >= NV);
end;
function InitializeSetup(): Boolean;
var
WindowsVersion: TWindowsVersion;
begin
if not WizardSilent() then begin
GetWindowsVersionEx(WindowsVersion);
Result := true;
if WindowsVersion.NTPlatform and (WindowsVersion.Major = 5) and (WindowsVersion.Minor = 1) and (WindowsVersion.ServicePackMajor < 2) then begin
MsgBox(CustomMessage('WinXPSp2Msg'), mbError, MB_OK);
Result := false;
exit;
end;
if WindowsVersion.NTPlatform and (WindowsVersion.Major >= 5) and (not IsMinMSIAvailable(3,0)) then begin
neededDependenciesInstallMemo := neededDependenciesInstallMemo + ' ' + CustomMessage('MSI31Title') + #13;
msi31Path := ExpandConstant('{src}') + '\' + CustomMessage('DependenciesDir') + '\WindowsInstaller-KB893803-v2-x86.exe';
if not FileExists(msi31Path) then begin
msi31Path := ExpandConstant('{tmp}\msi31.exe');
if not FileExists(msi31Path) then begin
neededDependenciesDownloadMemo := neededDependenciesDownloadMemo + ' ' + CustomMessage('MSI31Title') + #13;
neededDependenciesDownloadMsg := neededDependenciesDownloadMsg + CustomMessage('MSI31Title') + ' (' + CustomMessage('MSI31DownloadSize') + ')' + #13;
isxdl_AddFile({#MSI31URL}, msi31Path);
downloadNeeded := true;
end;
end;
SetIniString('install', 'msi31', msi31Path, ExpandConstant('{tmp}\dep.ini'));
end;
// Check for required dotnetfx 3.5 installation
if (not RegKeyExists(HKLM, 'SOFTWARE\Microsoft\NET Framework Setup\NDP\v3.5')) then begin
neededDependenciesInstallMemo := neededDependenciesInstallMemo + ' ' + CustomMessage('DOTNET35Title') + #13;
dotnet35Path := ExpandConstant('{src}') + '\' + CustomMessage('DependenciesDir') + '\dotnetfx35.exe';
if not FileExists(dotnet35Path) then begin
dotnet35Path := ExpandConstant('{tmp}\dotnetfx35.exe');
if not FileExists(dotnet35Path) then begin
neededDependenciesDownloadMemo := neededDependenciesDownloadMemo + ' ' + CustomMessage('DOTNET35Title') + #13;
neededDependenciesDownloadMsg := neededDependenciesDownloadMsg + CustomMessage('DOTNET35Title') + ' (' + CustomMessage('DOTNET35DownloadSize') + ')' + #13;
isxdl_AddFile({#DotNet35URL}, dotnet35Path);
downloadNeeded := true;
end;
end;
SetIniString('install', 'dotnet35', dotnet35Path, ExpandConstant('{tmp}\dep.ini'));
end;
end;
end;
function NextButtonClick(CurPage: Integer): Boolean;
var
hWnd: Integer;
begin
Result := true;
if CurPage = wpReady then begin
hWnd := StrToInt(ExpandConstant('{wizardhwnd}'));
if downloadNeeded then
if MsgBox(CustomMessage('DownloadMsg1') + #13 + neededDependenciesDownloadMsg + #13 + CustomMessage('DownloadMsg2'), mbConfirmation, MB_YESNO) = IDNO then Result := false
else if isxdl_DownloadFiles(hWnd) = 0 then Result := false;
end;
end;
function UpdateReadyMemo(Space, NewLine, MemoUserInfoInfo, MemoDirInfo, MemoTypeInfo, MemoComponentsInfo, MemoGroupInfo, MemoTasksInfo: String): String;
var
s: string;
begin
if neededDependenciesDownloadMemo <> '' then s := s + CustomMessage('DependenciesDownloadTitle') + ':' + NewLine + neededDependenciesDownloadMemo + NewLine;
if neededDependenciesInstallMemo <> '' then s := s + CustomMessage('DependenciesInstallTitle') + ':' + NewLine + neededDependenciesInstallMemo + NewLine;
s := s + MemoDirInfo + NewLine + NewLine + MemoGroupInfo
if MemoTasksInfo <> '' then s := s + NewLine + NewLine + MemoTasksInfo;
Result := s
end;
I'm in the high-fidelity first class traveling set.
And I think I need a Lear jet.
modified on Thursday, May 29, 2008 10:56 AM
|
|
|
|
|
Hello spif2001,
first thank you for your fast answer.
Did you test your installer on a fresh XP installation already?
Only because I've also played around a little bit with that now and see two problems in your code:
1. .NET Framework 3.5 does need .NET Framework 1.x or 2.x to be installed first. Otherwise installer will fail (on a fresh XP - also with SP2 - .NET is not installed at all).
2. the .NET Framework 3.5 installer needs Windows installer 3.1 (yes, "3.1", "3.0" is not enough - coundn't believe that myself first ).
Both are no bigger problems, but should be considered.
Best regards
Andreas
http://www.ab-downloads.com[^]
|
|
|
|
|
1. Dotnetfx35 installs .Net 2.0 SP1 and .Net 3.0 as well as .Net 3.5.
2. Although it is called Windows Installer 3.0 it is actually the 3.1 installer - some MS naming issue, but if you look closer at my code, you can see it is the 3.1 that gets installed.
I have tried to install it many times on a fresh XP SP2 with no .Net at all and it works fine.
I'm in the high-fidelity first class traveling set.
And I think I need a Lear jet.
|
|
|
|
|
Hello spif2001,
1. strange, last time I tried the installer doesn't worked without installing .NET 2.0 first. But you're right, I can't reproduce this problem anymore. Therefore it had to be my fault. Sorry, forget this.
2. yes, I saw you're installing MSI 3.1 and that's correct, of course. But you check on version <3.0 and that's the problem. You should check on version <3.1, because on a clean Windows XP with SP2 exactly version 3.0 is installed and therefore the installer would not install version 3.1 in this case (which leads to an error when trying to install .NET 3.5 in next step).
Best regards
Andreas
http://www.ab-tools.com/English/[^]
|
|
|
|
|
2. You are probably right, and I am now unsure as to wether I tested the Windows Installer part or not. The .Net part definitely works.
I'll try it tomorrow and see how it goes. If you are right, I'll update the above code. We can't have incorrect code lying around in here now can we?
I'm in the high-fidelity first class traveling set.
And I think I need a Lear jet.
|
|
|
|
|
I struggled the whole day yesterday with a vs2005 Setup and Deployment project just to have my app start AFTER the install was over, not during. I failed. Luckily I found InnoSetup and ISTool, and then this great article that would take care of my last setup problem: prerequisites:
So if I understand, to my existing iss script, I have to add to top and botton portion found in Setup.iss. I also see that you have an #include "isxdl.iss" which points to a dll.
Would it be possible to use an #include type process to move everything prerequisite a different file?
This would make my Setup1.iss just focused on the specifics of my App1.
Thanks
|
|
|
|
|