23

I'm using InstallShield 2010. I want to check whether .NET framework 4.5 is installed or not on the machine.

I can check .NET framework 4.0 is installed or not from registry, but I'm unable to find any registry key for .NET framework 4.5.

ROMANIA_engineer
  • 54,432
  • 29
  • 203
  • 199
Harish Reddy
  • 275
  • 1
  • 2
  • 7
  • Harish Reddy - if the answer was helpful for you - upvote is please. If it was the solution - upvote + accept – MikroDel Oct 09 '13 at 06:58

3 Answers3

33

According to the MSDN article here: http://msdn.microsoft.com/en-us/library/hh925568(v=vs.110).aspx

To find the installed .NET Framework versions manually (versions 4.5 and later)

  • On the Start menu, choose Run.
  • In the Open box, enter regedit.exe. (You must have administrative credentials to run regedit.exe.)
  • In the Registry Editor, open the following subkey: HKEY_LOCAL_MACHINE\SOFTWARE\Microsoft\NET Framework Setup\NDP\v4\Full Check for a DWORD value named Release. The existence of the Release DWORD indicates that the .NET Framework 4.5 or newer has been installed on that computer.

In other words under InstallShield, check for the existence of the Release DWORD at the registry location HKEY_LOCAL_MACHINE\SOFTWARE\Microsoft\NET Framework Setup\NDP\v4\Full

Community
  • 1
  • 1
DDA
  • 991
  • 10
  • 28
  • don't get mixed with v4.0! you might have in registry both: v4 and v4.0 ->look at v4\Full (not v4.0) for that entry - "Release" – Teo Jan 31 '19 at 14:54
12

Form Blog .NET 4.5 is an in-place replacement for .NET 4.0 and similar SO answer

HKEY_LOCAL_MACHINE\SOFTWARE\Microsoft\NET Framework Setup\NDP\v4\Client

check the Version value there.

If it starts with "4.0" you are running on the 4.0 runtime, if it starts with "4.5" you are running on the 4.5 runtime.

Community
  • 1
  • 1
MikroDel
  • 6,705
  • 7
  • 39
  • 74
  • One thing that is a very big source of confusion for developers is the difference between .Net framework version and CLR version. The two are NOT same. CLR version doesn't change as often as .Net framework does. Check the section "Versions of the Common Language Runtime" on [this](https://msdn.microsoft.com/en-us/library/8bs2ecf4(v=vs.110).aspx) link. To know CLR version use "clrver" command in visual studio command prompt. For .Net framework version you should rely on registry entries as correctly answered by DDA below. – RBT Feb 13 '16 at 02:55
6

As of 2015-06-01, The way to check any version up to 4.6 is described at MSDN: How to: Determine Which .NET Framework Versions Are Installed

Eric Ouellet
  • 10,996
  • 11
  • 84
  • 119