Users can install and run multiple versions of the .NET Framework on their computers. When you develop or deploy your app, you might need to know which .NET Framework versions are installed on the user’s computer. The registry contains a list of the .NET Framework versions installed on a computer.
-->
The .NET Framework consists of two main components, which are versioned separately:
The version of.NET Framework (4.5 and later) installed on a machine is listed in the registry at HKEYLOCALMACHINE SOFTWARE Microsoft NET Framework Setup NDP v4 Full. If the Full subkey is missing, then.NET Framework 4.5 or above isn't installed. The runtime includes everything you need to run existing apps/programs built with.NET Framework. Download.NET Framework 4.5.2 Runtime. Developer Pack. The developer pack is used by software developers to create applications that run on.NET Framework, typically using Visual Studio. Download.NET Framework 4.5.2 Developer Pack. Microsoft.NET Framework 4.7.2 is a highly compatible, in-place update to.NET Framework 4, 4.5, 4.5.1, 4.5.2, 4.6, 4.6.1, 4.6.2, 4.7, and 4.7.1. The offline package can be used in situations in which the web installer cannot be used because of a lack of Internet connectivity. This package is larger than the web installer and does not include the language packs.
Community-maintained tools are available to help detect which .NET Framework versions are installed:
For information about detecting the installed updates for each version of the .NET Framework, see How to: Determine which .NET Framework updates are installed.
Detect .NET Framework 4.5 and later versions
The version of .NET Framework (4.5 and later) installed on a machine is listed in the registry at HKEY_LOCAL_MACHINESOFTWAREMicrosoftNET Framework SetupNDPv4Full. If the Full subkey is missing, then .NET Framework 4.5 or above isn't installed.
Note
The NET Framework Setup subkey in the registry path does not begin with a period.
The Release REG_DWORD value in the registry represents the version of .NET Framework installed.
Minimum version
To determine whether a minimum version of the .NET Framework is present, use the smallest Release REG_DWORD value for that version from the previous table.
For example, if your application runs under .NET Framework 4.8 or a later version, test for a Release REG_DWORD value that is greater than or equal to 528040.
Use Registry Editor
Use PowerShell to check for a minimum version
Use PowerShell commands to check the value of the Release entry of the HKEY_LOCAL_MACHINESOFTWAREMicrosoftNET Framework SetupNDPv4Full subkey.
The following examples check the value of the Release entry to determine whether the .NET Framework 4.6.2 or later is installed. This code returns
True if it's installed and False otherwise.
Query the registry using code
The following example checks the value of the Release entry in the registry to find the .NET Framework 4.5 and later versions that are installed:
This example follows the recommended practice for version checking:
Detect .NET Framework 1.0 through 4.0
Each version of .NET Framework from 1.1 to 4.0 is listed as a subkey at HKEY_LOCAL_MACHINESOFTWAREMicrosoftNET Framework SetupNDP. The following table lists the path to each .NET Framework version. For most versions, there's a Install REG_DWORD value of
1 to indicate this version is installed. In these subkeys, there's also a Version REG_SZ value that contains a version string.
Note
The NET Framework Setup subkey in the registry path does not begin with a period.
Important
If the app you're running is 32-bit and running in 64-bit Windows, the registry paths will be different than previously listed. The 64-bit registry is available in the HKEY_LOCAL_MACHINESOFTWAREWow6432Node subkey. For example, the registry subkey for .NET Framework 3.5 is HKEY_LOCAL_MACHINESOFTWAREWow6432NodeMicrosoftNET Framework SetupNDPv3.5.
Notice that the registry path to the .NET Framework 1.0 subkey is different from the others.
Use Registry Editor (older framework versions)
Query the registry using code (older framework versions)
Use the Microsoft.Win32.RegistryKey class to access the HKEY_LOCAL_MACHINESOFTWAREMicrosoftNET Framework SetupNDP subkey in the Windows registry.
Important
If the app you're running is 32-bit and running in 64-bit Windows, the registry paths will be different than previously listed. The 64-bit registry is available in the HKEY_LOCAL_MACHINESOFTWAREWow6432Node subkey. For example, the registry subkey for .NET Framework 3.5 is HKEY_LOCAL_MACHINESOFTWAREWow6432NodeMicrosoftNET Framework SetupNDPv3.5.
The following example finds the .NET Framework 1 through 4 versions that are installed:
Find CLR versions
The .NET Framework CLR installed with .NET Framework is versioned separately. There are two ways to detect the version of the .NET Framework CLR:
Microsoft Visual C++See also-->
If you are migrating from the .NET Framework 4.5 to 4.5.2, review the following topics for application compatibility issues that may affect your app:
ADO.NETADO.NET now attempts to automatically reconnect broken SQL connections
ASP.NETASP.NET MVC now escapes spaces in strings passed in via route parameters
No longer able to set EnableViewStateMac to false
Profiling ASP.Net MVC4 apps can lead to Fatal Execution Engine Error
CoreA ConcurrentDictionary serialized in .NET Framework 4.5 with NetDataContractSerializer cannot be deserialized by .NET Framework 4.5.1 or 4.5.2
ConcurrentQueue<T>.TryPeek can return an erroneous null via its out parameter
COR_PRF_GC_ROOT_HANDLEs are not being enumerated by profilers
Deserialization of objects across appdomains can fail
EventListener truncates strings with embedded nullsMicrosoft Net Framework 4.5.2 Taking Long
EventSource.WriteEvent impls must pass WriteEvent the same parameters that it received (plus ID)
Marshal.SizeOf and Marshal.PtrToStructure overloads break dynamic code
Some .NET APIs cause first chance (handled) EntryPointNotFoundExceptions
WinRT stream adapters no long call FlushAsync automatically on close
DataMicrosoft Net Framework Windows 10ADO.NET now attempts to automatically reconnect broken SQL connections
SqlConnection.Open fails on Windows 7 with non-IFS Winsock BSP or LSP present
Entity FrameworkEF no longer throws for QueryViews with specific characteristics
Opt-in break to revert from different 4.5 SQL generation to simpler 4.0 SQL generation
SerializationNetDataContractSerializer fails to deserialize a ConcurrentDictionary serialized with a different .NET version
Windows Communication Foundation (WCF)MinFreeMemoryPercentageToActiveService is now respected
Windows Presentation Foundation (WPF)Calling DataGrid.CommitEdit from a CellEditEnding handler drops focusMicrosoft .net Framework 4.5.2 Mac Version
Intermittently unable to scroll to bottom item in ItemsControls (like ListBox and DataGrid) when using custom DataTemplates
Scrolling a WPF TreeView or grouped ListBox in a VirtualizingStackPanel can cause a hang
Microsoft Net Framework 4.5.2 Mac FreeWPF spawns a wisptis.exe process which can freeze the mouseMicrosoft 4.5 Framework Download
Comments are closed.
|
AuthorWrite something about yourself. No need to be fancy, just an overview. ArchivesCategories |