PDA

View Full Version : Launch condition does not detect .net framework



nitsev
11-18-2004, 11:29 AM
If this has been answered before I apologize. I have searched but not found it.

I am trying to create a launch condition for my install. I don't want the install to download or install the .net framework but just inform the installer that it is required and stop the installation.
I have created a new launch condition that searches the registry. It has the following properties.
Registry Root: HKEY_LOCAL_MACHINE
Registry Key : SOFTWARE\Microsoft\.NETFramework\policy\v1.1
Registry value: blank (i.e there's nothing in that property field)

According to the online help leaving the registry values blank will cause it to look for the default value, which is (default) under that registry key.

It does not matter if the .net framework 1.1 is installed or not. ISX always gives me the message that it is NOT installed and stops the installation. I have verified that the registry key is there when installation is run. The key contain the values (Default) and a key called 4322 which I guess is the build number of the .net framework

What am I doing wrong?

TsungH
11-18-2004, 12:25 PM
RegLocator table can not be used to determine the presence of a registry key, but it can be used to search for the default value of a registry key if the default value has non-null data. For one of the discussions, please refer to this (http://community.installshield.com/showthread.php?t=135271&highlight=RegLocator).

To determine the latest version of .NET Framework installed on the system, you can use MsiNetAssemblySupport Property. For a complete list of properties, please refer to Property Reference (http://msdn.microsoft.com/library/default.asp?url=/library/en-us/msi/setup/property_reference.asp).

nitsev
11-18-2004, 05:28 PM
So what you're saying is that it is possible to detect a if a registry key exist only if it has values other than an empty default? What kind of brainless functionality is that? I guess that I can query the 4322 value but I assume that that value will change with a future build of .NET framework 1.1

Is there any better way of detecting if the .net framework is installed and what version? looking for a file or directory or something? I am a bit puzzled why this is not a standard part of the requirements sections, such as memory, cpu, check for IE etc.

Thanks for your reply

TsungH
11-18-2004, 05:39 PM
Please read the second part of my previous reply.
To determine the latest version of .NET Framework installed on the system, you can use MsiNetAssemblySupport Property. For a complete list of properties, please refer to Property Reference (http://msdn.microsoft.com/library/default.asp?url=/library/en-us/msi/setup/property_reference.asp).

nitsev
11-19-2004, 02:17 AM
How can I use that property to create a launch condition? Remember that this is IS Express, not Pro or Premier.

nitsev
11-19-2004, 02:54 AM
I have found some useful info at this blog. This method works add allows med to check for the presence of .net framework 1.1 regardless of what service pack that is installed.

http://blogs.msdn.com/astebner/archive/2004/09/14/229574.aspx

However I would still be interested in knowing how to read properties in a custom launch condition.

Thanks

TsungH
12-16-2004, 08:09 PM
I got my hands on a copy InstallShield X Express Edition. The bad news is, you can't use MsiNetAssemblySupport property directly to create a launch condition, Express IDE does not support that.

nitsev
12-17-2004, 02:29 AM
But thanks for letting me know for sure.

Regards
Fredrik

elziko
07-06-2005, 06:22 AM
Has anyone found another registry value we can try and check to acomplish this? The link to the blog above only helpes for checking for specific service packs.

It really is rediculous that you can't check for the existance of a registry key. I can't think of a legit reason why you'd not include this! Any chance of this being added?

TsungH
07-07-2005, 04:14 PM
I am pretty sure it's been discussed in the forums. Perhaps, you want to do a search on framework.
It really is rediculous that you can't check for the existance of a registry key. I can't think of a legit reason why you'd not include this! Any chance of this being added?You may want to direct that question to MS, it's, after all, MSI technology.

elziko
07-08-2005, 03:32 AM
Apologies, I assumed it was an Installshield issue.

JShumaker
12-07-2006, 06:27 PM
Regardless of what you use, conditional expressions in an MSI installer are all the same.

I personally wanted to check for any .net framework besides 1.0 and so i used the following launch condition:
MsiNetAssemblySupport<>"" And Not (MsiNetAssemblySupport<<"1.0")

Makes sure the value is not empty, and that it does not begin with 1.0. Full information on conditional syntax is available from Microsoft in the MSDN library:
http://msdn.microsoft.com/library/default.asp?url=/library/en-us/msi/setup/conditional_statement_syntax.asp