For. NET generated application, whether it is a managed application or an unmanaged application, there are problems during execution, such as the error of file not found,missing file, the first solution we think of is whether the machine has the corresponding. NET Framework installed. There are several ways to determine if the. NET framework and version are installed on this machine.
1. Search the Mscoree.dll file under the System folder (C:\WINDOWS\SYSTEM32), if the file exists, prove that the. NET framework platform is installed, view the properties of the file, and in the details bar, you can see the version information of the file. This represents the highest version of the native. NET Framework. However, it is not possible to see all of the. NET framework versions that have been installed natively in this way.
2. View the registry:
Open the registry and locate the HKEY_LOCAL_MACHINE\SOFTWARE\Microsoft\NET Framework SETUP\NDP, where you can see all of the installed. NET Framework versions.
3. This method is not a way to get the version of the. NET framework, but rather to get the CLR version of the method Using the tools provided by Microsoft Clrver.exe, the tool is installed automatically when installing VS, using the Clrver.exe method is to find the VS Command prompt tool under the VS installation folder, enter Clrver.exe to list the CLR version of the native installation, and why the CLR version does not represent. NET Version of the framework, because multiple. NET Framework versions may use a version of the CLR, which lists all Microsoft. NET Framework versions and their corresponding CLR versions,
. NET Framework version |
CLR version |
1.0 |
1.0 |
1.1 |
1.1 |
2.0 |
2.0 |
3.0 |
2.0 |
3.5 |
2.0 |
4.0 |
4.0 |
4.5 |
4.5 |
/table>
Visible CLR does not have 3.0 and 3.5.
How to determine the. NET Framework Version