cancel
Showing results for 
Show  only  | Search instead for 
Did you mean: 
DragonQ
Level 3

Problems with .NET 2.0 Requirement

Hi all,

I've got an installer for a simple program that only requires .NET 2.0 or later to function. I've tried two methods of making this a prerequesite and neither work:

1) In the Releases section, I go to the .NET/J# tab and set .NET Framework Location to "Download from Web" and set the version to 2.0. When I run the installer, it tells me that .NET 2.0 needs to be installed for the installation to continue and then....does nothing. It simply quits the installation (setup.exe disappears from the Task Manager process list). 😕

2) In the Redistributables section, I tick "Microsoft .NET Framework 2.0 SP1". When I start the installation, it tells me that I need to install .NET 2.0 SP1, despite the fact that I already have .NET 2.0 SP2 installed (as well as .NET 3.5 SP1).

For the first method, am I doing something wrong or is this a bug? For the second method, I'm guessing this is somewhat designed behaviour.

All I want is for the program to download and install .NET 2.0 SP1 if .NET 2.0 SP1 or later is not on the system - is this possible?


Thanks,

DragonQ.
Labels (1)
0 Kudos
(5) Replies
DragonQ
Level 3

Any help?

I managed to use the second method above and tweak the condition slightly to make it require any version of .NET 2.0 (normal or SP1) but I still can't figure out how to make it require any version of .NET 2.0 or 3.0/3.5. 😕
0 Kudos
mobinet
Level 2

I wouldn't suggest trying to have the system accept 3.0 .NET when 2.0 is what is actually required. Having 3.0 doesn't mean that it supports 1.0,1.1,2.0 etc. as they designed to be exclusive of each other.

Can I ask how you setup the prerequisites to accept 2.0 SP2 as being installed as the necessary version?
0 Kudos
MichaelU
Level 12 Flexeran
Level 12 Flexeran

Actually, .NET 3.0 and 3.5 don't work quite as you might expect. They are additional libraries along side a 2.0 implementation of the core framework. Thus in order to have either 3.0 or 3.5, you must have 2.0. I believe the trend will go back to normal with the next major release of the .NET framework, however, so don't count on this in the future.

As for detecting it, check Aaron Stebner's blog for extra details. In general, since .NET 1.1, the "NDP" key (HKLM\Software\Microsoft\Net Framework Setup\NDP) and its subkeys are the best way to detect versions of .NET. Unfortunately since they use version-named subkeys, there's not a general way in our prerequisite architecture to allow any newer version to count as any older version unless explicitly listed.
0 Kudos
loyalp
Level 5

DragonQ wrote:

2) In the Redistributables section, I tick "Microsoft .NET Framework 2.0 SP1". When I start the installation, it tells me that I need to install .NET 2.0 SP1, despite the fact that I already have .NET 2.0 SP2 installed (as well as .NET 3.5 SP1).


I think the InstallShield .NET Framework 2.0 SP1 Prerequisite is erroneous.

The Conditions are set to check the registry for the SP value, and install if it is "not equal" to the value: 1. Which, of course if you have .NET 2.0 SP 2 installed, it is set to the value: 2.

The prerequisite should be set to check for a value "less than" 1.
0 Kudos
DragonQ
Level 3

Yes, I originally changed that condition to "less than 1".

I think I'll try the NDP method of checking for a "v2.0.50727" key - it seems my Vista VPC (which obviously only comes with 3.0 installed) has that key so that should work, although would this key change if an update for 2.0 is released?
0 Kudos