Как узнать версию net framework в windows 10 cmd

В Windows одновременно можно одновременно установить и запустить несколько версий .NET Framework. При разработке или развертывания нового приложения, основанного на библиотеках .NET, иногда нужно предварительно узнать какие версии и пакеты обновления .Net Framework уже установлены на компьютере пользователя или на сервере. Вы можете получить список версий .NET Framework, установленных на компьютере, несколькими способами.

Содержание:

  • Информация об установленных версиях .NET Framework в реестре
  • Как узнать версию .NET Framework с помощью PowerShell?
  • Проверить версию .Net Framework на удаленных компьютерах
  • Вывести версии .NET Framework в командной строке

Информация об установленных версиях .NET Framework в реестре

При установке или обновлении любой версии .NET Framework, изменения записываются в реестр Windows.

Откройте редактор реестра (regedit.exe) и перейдите в раздел HKLM\ SOFTWARE\Microsoft\NET Framework Setup\NDP. В этой ветке хранится информация обо всех версиях .NET на компьютере. Разверните любой раздел и обратите внимание на следующие параметры (для .Net 4.x нужно развернуть ветку Full):

  • Install — флаг установки (если равен 1, значит данная версия .Net установлена на компьютере);
  • Install Path — каталог, в который установлена данная версия .Net;
  • Release — номер релиза .Net;
  • Version — полный номер версии .Net Framework.

версии .Net Framework в реестре

Примечание. Для .NET 4.0 и выше, если подраздел Full отсутствует, это значит, что данная версия Framework на компьютере не установлена.

К примеру, в данном примере видно, что на компьютере установлены .NET Framework v2.0.50727, 3.0, 3.5 и 4.7 (релиз 460805).

Обратите внимание, что в серверных ОС начиная с Windows Server 2012, все базовые версии .Net (3.5 и 4.5) является частью системы и устанавливаются в виде отдельного компонента (Установка .NET Framework 3.5 в Windows Server 2016, в Windows Server 2012 R2), а минорные (4.5.1, 4.5.2 и т.д.) устанавливаются уже в виде обновлений через Windows Update или WSUS.

С помощью следующей таблицы вы можете установить соответствие между номером релиза и версией .NET Framework (применимо к .NET 4.5 и выше).

Значение DWORD параметра Release Версия .NET Framework
378389 .NET Framework 4.5
378675 NET Framework 4.5.1 на Windows 8.1 / Windows Server 2012 R2
378758 .NET Framework 4.5.1 на Windows 8, Windows 7 SP1, Windows Vista SP2
379893 .NET Framework 4.5.2
393295 .NET Framework 4.6 на Windows 10
393297 .NET Framework 4.6
394254 .NET Framework 4.6.1 на Windows 10 1511
394271 .NET Framework 4.6.1
394802 .NET Framework 4.6.2 на Windows 10 1607
394806 .NET Framework 4.6.2
460798 .NET Framework 4.7 на Windows 10 1703
460805 .NET Framework 4.7
461308 .NET Framework 4.7.1 на Windows 10 1709
461310 .NET Framework 4.7.1
461808 .NET Framework 4.7.2 на Windows 10 1803
461814 .NET Framework 4.7.2
528372 .NET Framework 4.8 на Windows 10 2004, 20H2, и 21H1
528040 .NET Framework 4.8 на Windows 10 1903 и 1909
528449 .NET Framework 4.8 в Windows Server 2022 и Windows 11
528049 .NET Framework 4.8 (остальные версии Window)

.NET Framework 4.8 сегодня — самая последняя доступная версия .NET Framework.

Как узнать версию .NET Framework с помощью PowerShell?

Можно получить информацию об установленных версиях и релизах NET Framework на компьютере с помощью PowerShell. Проще всего получить эти данные напрямую из реестра с помощью командлетов
Get-ChildItem
и
Get-ItemProperty
(подробнее о работе с записями реестра из PowerShell).

Чтобы вывести таблицу по всем версиям .Net Framework на компьютере, выполните команду:

Get-ChildItem ‘HKLM:\SOFTWARE\Microsoft\NET Framework Setup\NDP’ -Recurse | Get-ItemProperty -Name version -EA 0 | Where { $_.PSChildName -Match ‘^(?!S)\p{L}’} | Select PSChildName, version

вывести список установленных версий .net framework с помощью powershell

На этом компьютере установлены версии .Net 2.0, 3.0, 3.5 и 4.7.

Начиная с версии .Net v4.0 более новая версия Framework перезаписывает (заменяет) старую версию. Т.е. если на компьютере был установлен .NET Framework 4.7, то при установке .NET Framework 4.8, старая версия пропадет.

Можно вывести только номер релиза (для версий .Net 4.x):

(Get-ItemProperty ‘HKLM:\SOFTWARE\Microsoft\NET Framework Setup\NDP\v4\Full’  -Name Release).Release

получить номер релиза net framework из консоли powershell

Согласно таблице, номер 528449 соответствует версии .Net Framework 4.8 в Windows 11.

Проверить версию .Net Framework на удаленных компьютерах

Вы можете удаленно получить список версий .Net Framework, установленных на компьютерах в вашей сети помощью PowerShell.

Ниже представлен небольшой PowerShell скрипт, который получает список компьютеров из текстового файла и проверяет на всех версию .Net Framework. Для запуска команд на удаленных компьютерах используется WinRM командлет Invoke-Command.

Function GetNetFramework {
Get-ChildItem 'HKLM:\SOFTWARE\Microsoft\NET Framework Setup\NDP' -recurse |
Get-ItemProperty -name Version,Release -EA 0 |
Where { $_.PSChildName -match '^(?![SW])\p{L}'} |
Select PSChildName, Version, Release, @{
name="Product"
expression={
switch -regex ($_.Release) {
"378389" { [Version]"4.5" }
"378675|378758" { [Version]"4.5.1" }
"379893" { [Version]"4.5.2" }
"393295|393297" { [Version]"4.6" }
"394254|394271" { [Version]"4.6.1" }
"394802|394806" { [Version]"4.6.2" }
"460798|460805" { [Version]"4.7" }
"461308|461310" { [Version]"4.7.1" }
"461808|461814" { [Version]"4.7.2" }
"528040|528049|528449|528372" { [Version]"4.8" }
{$_ -gt 528449} { [Version]"Undocumented version (> 4.8)" }
}
}
}
}
$result=@()
$servers= Get-Content C:\PS\servers.txt
foreach ($server in $servers)
{
$result+=Invoke-Command -ComputerName $server -ScriptBlock $function:GetNetFramework
}
$result|  select PSComputerName,@{name = ".NET Framework"; expression = {$_.PSChildName}},Product,Version,Release| Out-GridView

Скрипт выводит табличку (через Out-GridView) со списком версий .Net Framework, установленных на удаленных компьютерах.

poweshell скрипт для получения версий net framework на удаленных компьютерах

Также вы можете задать список компьютеров, на которых нужно проверить .NET так:

$servers= @("pc1","pc2","pc3","pc4","pc5")

Или выбрать список компьютеров из домена с помощью командлета Get-ADComputer из модуля AD PowerShell. Следующая команда выберет все активные хосты Windows Server в домене:

$servers= Get-ADComputer -Filter 'operatingsystem -like "*Windows server*" -and enabled -eq "true"'

Вывести версии .NET Framework в командной строке

Все версии.NET Framework устанавливаются в следующие каталоги Windows:

  • %SystemRoot%\Microsoft.NET\Framework
  • %SystemRoot%\Microsoft.NET\Framework64

Вы можете просто открыть этот каталог и увидеть список установленных версий .NET. Каждой версии соответствует отдельный каталог с символом v и номером версии в качестве имени папки. Можно вывести список установленных версий .NET Framework из команды строки:

dir %WINDIR%\Microsoft.Net\Framework\v* /O:-N /B

узнать версию net framework из командной строки windows

Команда выведет все установленные версии кроме 4.5, т.к. .NET Framework 4.5 устанавливается в подкаталог v4.0.xxxxx.

Check .NET Framework version

Check .NET Framework version
(Image credit: Future)

On Windows 11 (and 10), the «.NET Framework» («dot net») is a development platform made up of programming languages, libraries, and tools for programmers to build different types of programs for desktops, laptops, tablets, servers, web apps, and games.

The .NET platform is not limited to Windows since it is open-source and cross-platform, which means it’s also supported on macOS and Linux devices.

Although regular users rarely have to worry about the version of .NET installed on their devices, some apps require specific releases to install and run as properly. In addition, developers usually have to use multiple versions of the development platform to build and test their apps. As a result, knowing the version of .NET installed on the computer can come in handy in many scenarios.

Whether you are a developer or a standard user, Windows 11 (and 10) provides several methods to determine the .NET Framework version through File Explorer, Registry, Command Prompt, and PowerShell.

This how-to guide will walk you through the steps to determine the .NET Framework version installed on Windows 11.

How to check .NET version using File Explorer

To use File Explorer to check the .NET Framework version on Windows 11, use these steps:

  1. Open File Explorer.
  2. Browse the following path: C:\Windows\Microsoft.NET\Framework
  3. Open the folder with the latest version – for example, v4.0.30319.

File Explorer Framework folder

(Image credit: Future)
  1. Right-click any of the «.dll» files and select the Properties option.

Framework files properties

(Image credit: Future)
  1. Click the Details tab.
  2. In the «Product version» section, confirm the version of .NET – for example, 4.8.9032.0.

Check .NET Framework version with File Explorer

(Image credit: Future)

Once you complete the steps, the file details will unveil the framework platform’s version installed on Windows.

All the latest news, reviews, and guides for Windows and Xbox diehards.

How to check .NET version using Registry

To determine the .NET Framework version through the Registry, use these steps:

  1. Open Start.
  2. Search for regedit and click the top result to open the Registry.
  3. Browse the following path: HKEY_LOCAL_MACHINE\SOFTWARE\Microsoft\NET Framework Setup\NDP
  4. Expand the main version key – for example, v4 or v4.0.
  5. Select the Client key.
  • Quick tip: In releases older than version 4, the key will be a number or «Setup.» For example, .NET version 3.5 includes the version number under the 1033 key.

Check .NET Framework version with Registry

(Image credit: Future)
  1. On the right, check the «Version» string to determine the release of the .NET Framework.

After you complete the steps, you will know the releases of the Microsoft framework available on your version of Windows.

How to check .NET version with Command Prompt

To check the version of the .NET Framework with Command Prompt on Windows 11, use these steps:

  1. Open Start.
  2. Search for Command Prompt, right-click the top result, and select the Run as administrator option.
  3. Type the following command to determine the version of .NET installed on Windows and press Enter: reg query «HKLM\SOFTWARE\Microsoft\Net Framework Setup\NDP» /s 

To make sure that version 4.x is installed, use this variant of the command: reg query «HKLM\SOFTWARE\Microsoft\Net Framework Setup\NDP\v4» /s

Command Prompt check dotnet version command

(Image credit: Future)
  1. Check the «Version» field to confirm the releases of the .NET Framework installed on Windows 11.

Once you complete the steps, the versions of .NET running on the computer will be revealed.

How to check .NET version with PowerShell

To check the .NET version with PowerShell on Windows 11, use these steps:

  1. Open Start.
  2. Search for PowerShell, right-click the top result, and select the Run as administrator option.
  3. Type the following command to check the version of .NET installed and press Enter: Get-ChildItem ‘HKLM:\SOFTWARE\Microsoft\NET Framework Setup\NDP’ -Recurse | Get-ItemProperty -Name version -EA 0 | Where { $_.PSChildName -Match ‘^(?!S)\p{L}’} | Select PSChildName, version

PowerShell check version of .NET command

(Image credit: Future)
  1. Confirm the version of the .NET Framework installed on the computer.

After you complete the steps, PowerShell will return the information for both the client and the full version of .NET installed on Windows 11 (or 10) (if applicable).

More resources

For more helpful articles, coverage, and answers to common questions about Windows 10 and Windows 11, visit the following resources:

  • Windows 11 on Windows Central — All you need to know
  • Windows 10 on Windows Central — All you need to know

Mauro Huculak has been a Windows How-To Expert contributor for WindowsCentral.com for nearly a decade and has over 15 years of experience writing comprehensive guides. He also has an IT background and has achieved different professional certifications from Microsoft, Cisco, VMware, and CompTIA. He has been recognized as a Microsoft MVP for many years.

Although, checking the version of the .NET framework is not necessary for the most part.

But if you are a programmer and have to run multiple versions of the platform to build an app then you might want to consider gaining the knowledge of your computer’s .NET framework.

What is the .NET framework? 🤔

If you are a programmer then the chances of you knowing .NET framework are high. But if you are a layman then this subset is especially for you.

A framework is a basic requirement to run something, for example, an engine of a car is its framework. So, in the same manner, there are software frameworks.

They are nothing but a piece of written codes which is used to build software of a particular type

The .NET framework is a software framework provided by Microsoft to act as a base for more complex coding in Windows. Therefore, it can be used to build both Form and web-based applications.

.NET framework architecture:-

These are the following components of .NET Framework Architecture:-

6 Ways To Check .NET Framework Version on Windows 10

.NET Class Library:- One of the best features of the .NET framework architecture is the .NET class library. It has multiple classes stored in them, and all of them are readily available for the clients to use.

CLR:- CLR stands for Common Language Runtime. The Common Language Runtime makes the .NET Framework multilinguistic as it allows the framework to be interoperable by switching between multiple different languages such as C, C++, VB, Visual, etc.

They provide a common environment for implementing the codes written in different programming languages.

DLR:- DLR or Dynamic Language Runtime makes the .NET Framework to execute Dynamic Languages by adding some more features to the CLR.

Application Domain: It acts like a logical wall that prevents an application from accessing another application.

.NET Framework Security:- As the name suggests .NET Framework Security aims to provide the users with the total security of their codes and resources from the hacker.

Cross-Language Interoperability: If you have created the code in one language and want to execute it in another language, that is when Cross-Language Interoperability will come into the act.

Side-by-Side execution: Because of Side-by-Side execution, a user can use multiple versions of CLR simultaneously.

Common Type System: CTS or Common Type System is a collection of rules that all the data types must abide by. It aims to standardize the codes as when we type a code in any language and want it to interact with each other.

For that purpose, you have the Common Type System(CTS) as it will standardize the data types.

These are the components of the .NET Framework.

Check .NET Framework Version

Checking the .NET framework version is an easy task. And this is subset will make this task even easier. Here are 4 techniques that one can use to check the .NET framework version in Windows.

1. By Command Prompt:-

You can do zillions of things with the help of command prompt and checking your computer’s .NET framework is one of them. Just follow the following steps and you will be able to check your .NET framework.

Step1:- Launch “command prompt” by either searching it out from the Start menu or press “Windows + R” to launch it via RUN.

Note: Make sure to open the command prompt in administrator mode, to open the command prompt in administrator mode via RUN, press “CTRL + SHIFT + ENTER”

Step2: In the command prompt type(copy-paste)

reg query “HKLM\SOFTWARE\Microsoft\Net Framework Setup\NDP” /s

Check .Net Framework Version

So, this how you can check your .NET framework version. As in this example, the framework is “4.0.30319”.

This is how you can see your Check .Net Framework Version via Command Prompt.

2. By PowerShell

Microsoft is trying to shifts its user from one command-based application, Command Prompt to another command-based application PowerShell. PowerShell is a more glamorous approach toward the command line.

As I said earlier PowerShell is just like a command prompt. So, it exhibits the same feature with some twitch in commands.

Here is how you can check your .NET version with PowerShell:-

Step 1: Launch PowerShell by the start menu(open in admin mode or use the shortcut key “Windows + X”. Click “A” on the keyboard.

Step 2: In the appeared window type the below command and hit enter

Get-ChildItem ‘HKLM:\SOFTWARE\Microsoft\NET Framework Setup\NDP’ -Recurse | Get-ItemProperty -Name version -EA 0 | Where { $_.PSChildName -Match ‘^(?!S)\p{L}’} | Select PSChildName, version

6 Ways To Check .NET Framework Version on Windows 10

Now, you can observe the output as it unravels the information of both the client and the version of the .NET framework.

This is how you can see your Check .Net Framework Version via PowerShell.

3. By Registry Editor:-

The Registry Editor in windows is a database that stockpiles all the low-level settings and the apps that supports the use of the registry. The registry editor can be used for checking your “.NET framework”.

Just follow the prescribed steps and you will be able to check your .NET version.

Open Registry Editor either from the start menu( search registry editor) or launch RUN by clicking Windows + R, afterward type “Regedit” and hit enter to go.

Search for HKEY_LOCAL_MACHINE, click on the dropbox.

From the dropbox navigate as Software> Microsoft> NET Framework Setup>NDP.

Select the main version, like v4.0.

Click on the client key.

Here you can see the version of the .NET framework you are using.

So, that is how you can search for your .NET version without having to write a command.

4. By DotNetVersionLister

There is a tool in the GitHub community tool that will allow you to see the versions of the .NET framework installed on your computer.

Now to use DotNetVersionLister perform the following steps:-

Step 1: Launch PowerShell in admin mode.

Step 2: In PowerShell’s command line type  “Install-Module -Name DotNetVersionLister -Scope CurrentUser #-Force” and install this tool on your device.

Step 3: Press Y to say yes and agree to the terms.

Step 4: Now, type “Get-STDotNetVersion” and hit enter.

All the installed version will appear on your screen.

Check .Net Framework Version

5. By .NET Version

.NET version (Download Here) is an OG in this field. It has been in the market for ages. And it still works. Therefore, it is one of the best ways to check all the .NET version installed on your computer.

Note: Always run this program in administrator mode.

6 Ways To Check .NET Framework Version on Windows 10

It also allows the user to check the version of the internet explorer installed on your computer.

This software provides with numerous buttons such as “copy to clipboard”, “printing an email” and “Zip”

This is one of the oldest and most reliable technique. You do not need to write a long command as you did in command prompt and PowerShell.

These all were the technique by which you can check the .NET framework version of your operating system.

6. Using Revo Uninstaller

You might be surprised by seeing Revo uninstaller (Download Here) in this list, but Revo uninstaller is not the only uninstaller you are also able to view the installed version of installed applications.

As you saw in the below screenshot this application is not only showing the installed applications, it’s showing the installed version applications along with the installed date of the application and the company.

Check .NET Framework Version

How to repair the .NET Framework?

If you are facing some issues with your .NET framework and are deciding what to do then you should try and repair it. In this subsection, we are going to teach you “how to troubleshoot .NET framework”.

To do that first of all you have to download and run Microsoft .NET Framework Repair Tool.

6 Ways To Check .NET Framework Version on Windows 10

At the same time, it is recommended to run the system file checker, to do that just be obedient to the following steps.

Step 1: Open command prompt as an administrator from either the start menu or the run(windows + r).

Step 2: type “SFC /SCANNOW” and hit enter.

This command will scan your problem and see if it is resolved or not.

How to Uninstall the .NET Framework?

Newer versions of Microsoft Windows such as Windows 8 and above does not provide the feature of Uninstalling your .NET Framework. Windows 8 and above do not consider “Microsoft .NET” as an installed program but it considers it as a default program.

To do that just follow the steps prescribed below:-

Step 1: Search for “Programs and Features” in your control panel.

Step 2: Search .NET Framework and uninstall it by right-clicking on the icon.

Note: It is better to repair your .NET framework rather than uninstalling it.

📗FAQ

How to check .NET Framework version cmd?

To check the .NET Framework version using cmd, use the command “reg query “HKLM\SOFTWARE\Microsoft\NET Framework Setup\NDP””. This will display a list of installed .NET Framework versions.

How to check .NET Framework version using PowerShell command?

To check the .NET Framework version using PowerShell, use the command “Get-ChildItem ‘HKLM:\SOFTWARE\Microsoft\NET Framework Setup\NDP’ -recurse | Get-ItemProperty -name Version, Release -EA 0 | Where { $_.PSChildName -match ‘^v4.’ } | Select PSChildName, Version, Release”.

This will display a list of installed .NET Framework versions and their corresponding release numbers.

What version of .NET Core do I have?

To check the version of .NET Core you have installed, you can run the command “dotnet –version” in the command prompt or terminal.

How do I check my .NET Framework version in App Service?

To check the .NET Framework version in App Service, you can navigate to the App Service’s “Configuration” settings and look for the “Stack settings” section. The version of .NET Framework being used should be listed there.

What is the difference between .NET and .NET Framework?

.NET is a general term that refers to Microsoft’s entire family of programming frameworks, including .NET Framework, .NET Core, and Xamarin. .NET Framework is a specific implementation of the .NET programming framework that is primarily used for developing Windows desktop applications.

How do I check the version of .NET Framework in IIS?

To check the version of .NET Framework in IIS, you can navigate to the “Application Pools” section, select the appropriate application pool, and click on “Advanced Settings”. The version of .NET Framework being used should be listed under “General” settings.

How do I update my .NET Framework?

You can update your .NET Framework by downloading and installing the latest version from the Microsoft website, or by using the Windows Update feature.

What is the difference between .NET Framework and .NET Core?

.NET Framework and .NET Core are both implementations of the .NET programming framework. Still, they differ in a few key ways. .NET Framework is primarily used for developing Windows desktop applications.

At the same time, .NET Core is cross-platform and can be used to develop applications for Windows, Linux, and macOS. Additionally, .NET Core is open-source and designed to be more lightweight than .NET Framework.

How to check module version in PowerShell?

To check the version of a module in PowerShell, you can use the Get-Module command followed by the name of the module and the “-ListAvailable” parameter. This will display a list of installed modules and their corresponding version numbers.

How to use .NET command line?

To use the .NET command line, you can open a command prompt or terminal and type “dotnet” followed by the name of the command you want to use. For example, “dotnet new” creates a new .NET project.

How do I access .NET framework?

You can access .NET Framework by installing it on your computer and using it to develop Windows desktop applications. You can also access .NET Framework through integrated development environments (IDEs) such as Visual Studio.

Where do I change my .NET framework version?

You can change your .NET Framework version by navigating to the appropriate settings in your development environment, such as Visual Studio or Visual Studio Code, and selecting the desired version of the framework.

How to change the net Framework version in console application?

To change the .NET Framework version in a console application, you can edit the “Target Framework” setting in the project file or in the project’s properties.

Can I install .NET Framework and .NET Core on the same machine?

Yes, you can install both .NET Framework and .NET Core on the same machine without any issues.

Should I use .NET 6 or .NET Framework?

The choice between .NET 6 and .NET Framework depends on your specific needs and the requirements of your project. .NET Framework is best suited for developing Windows desktop applications, while .NET 6 is a cross-platform framework that can be used to develop a wide range of applications.

How do I find the .NET framework version of a website?

You can find the .NET Framework version of a website by inspecting the web.config file in the root directory of the website. The version number will be listed in the “system.web” section.

Is .NET framework required for IIS?

Yes, .NET Framework is required for IIS if you want to run ASP.NET web applications on the server.

How do I know if dotnet 3.5 is installed?

You can check if .NET Framework 3.5 is installed by navigating to the “Programs and Features” section in the Control Panel and looking for it in the list of installed programs.

Why is .NET 4.8 recommended?

.NET 4.8 is recommended because it is the latest version of .NET Framework and includes many new features and improvements over previous versions.

How do I know if .NET Framework 4.8 is installed?

You can check if .NET Framework 4.8 is installed by navigating to the “Programs and Features” section in the Control Panel and looking for it in the list of installed programs.

Summary:-
  • The .NET framework is a software framework provided by Microsoft to act as a base for more complex coding in Windows.
  • Components of .NET framework architectur are .NET Class Library,Common Language Runtime(CLR), Dynamic Language Runtime(DLR), Application domain, .NET Framework, Cross Language Interoperability, Side-by-Side execution, Common Type System.
  • There are five methods of checking your current .NET Framework:-
  1. By Command Prompt, command “reg query “HKLM\SOFTWARE\Microsoft\Net Framework Setup\NDP” /s”
  2. By PowerShell, command “Get-ChildItem ‘HKLM:\SOFTWARE\Microsoft\NET Framework Setup\NDP’ -Recurse | Get-ItemProperty -Name version -EA 0 | Where { $_.PSChildName -Match ‘^(?!S)\p{L}’} | Select PSChildName, version
  3. By Registry Editor
  4. By DotNetVersionLister
  5. By NET version

 To repair the .NET framework, download and run Microsoft .NET Framework Repair Tool, for confirmation write “SFC /SCANNOW”.

To uninstall .NET framework go to your program files and uninstall. Note: It is only applicable in windows prior to Windows 8.

With the release of each new version of .NET Framework, users are bound to install as many framework versions as possible as some applications require .NET Framework version 3.5 and some will work only on version 2.0. Microsoft does not give an easy way to check which versions of .NET Framework are installed on a Windows system.

Nope, you can’t check it from Apps and Features or Programs and Features!

We have already share a software called .NET Framework detector which can list down the frameworks installed and supported by your system. Although it is an easier way to check but sometimes it becomes difficult to install the software on every system if you are a developer or a network admin.

Table of Contents

Windows 10 Version 1803 has .NET Framework 4.7.2 installed by default. There are a few ways we can check which versions of .NET Framework are installed using command line. Let’s go through them one by one.

How to check .NET Framework Version Using Command Line

1- Using Windows directory

Here we are going to check which .Net Framework is installed on your computer through command line.

Simply open command Prompt from the start and then type any of the following commands

dir %windir%\Microsoft.NET\Framework /AD

2 Ways to Check .NET Framework Version Using Command Line 1

It will show the list of all the directories with all the versions installed along with the latest ones.

Once you are in the directory then to check which latest version is installed type

.\MSBuild.exe -version

For example, if I want to check the exact version for .NET Framework 4, I will run the following commands in sequence:

dir %windir%\Microsoft.NET\Framework /AD

cd %windir%\Microsoft.NET\Framework\v4.0.30319

.\MSBuild.exe -version

2- Using WMIC

You can list down the default (latest one) .NET Framework being used by the system using the WMIC command:

wmic product get description | findstr /C:.NET

If you want a list of all versions installed on your computer, you can also use the following command:

dir /b %windir%\Microsoft.NET\Framework\v*

This command is basically a rip-off of the first method we used above. This will not give you the exact version number as you still have to use the MSBuild command as listed above to get the exact version number.

Which method do you use for checking the installed .NET Framework version?

В ОС Windows одновременно может быть установлено несколько версий .NET Framework. При установке на компьютере нового приложения, разработанного на .Net, иногда нужно предварительно узнать какие версии и пакеты обновления .Net Framework уже установлены на компьютере пользователя или на сервере. Получить список установленных версий .NET Framework можно разными способами.

Содержание:

  • Выводим список установленных версий .NET Framework в командной строке
  • Информация об установленных версиях .NET Framework в реестре
  • Проверка версии .Net Framework с помощью Powershell
  • Утилита .Net Version Detector
  • Утилита CLRver.exe

Выводим список установленных версий .NET Framework в командной строке

Все версии .NET Framework устанавливаются в каталоги:

  • %SystemRoot%\Microsoft.NET\Framework
  • %SystemRoot%\Microsoft.NET\Framework64

Поэтому самый простой способ вывести список установленных версий .Net – открыть данную папку. Каждой версии соответствует отдельный каталог с символов v в начале и номером версии в качестве имени папки. Либо можно вывести список каталогов (версий) .NET Framework в командной строке так:

dir %WINDIR%\Microsoft.Net\Framework\v* /O:-N /B

dir %WINDIR%\Microsoft.Net\Framework

Команда выведет все установленные версии кроме 4.5, т.к. .NET Framework 4.5 устанавливается в подкаталог v4.0.xxxxx.

Информация об установленных версиях .NET Framework в реестре

При установке или обновлении любой версии .NET Framework в реестр записывается довольно много полезной информации.

Откройте редактор реестра и перейдите в раздел HKLM\SOFTWARE\Microsoft\NET Framework Setup\NDP. В данном разделе содержатся подраздел для каждой установленной в системе версии .NET. Нужная информация содержится в разделе с именем ветки (а для .Net 4.0 и выше в подразделах Client и Full). Нас интересуют следующие параметры реестра:

  • Install — флаг установки версии (если равен 1 – данная версия .Net установлена на компьютере);
  • Install Path — каталог, в который установлена данная версия .Net;
  • Release — номер текущего релиза .Net;
  • Version — полный номер версии .Net Framework.

версии .Net Framework в реестре

К примеру, в данном примере видно, что на компьютере установлены .NET Framework v2.0.50727, 3.0, 3.5 и 4.0 (релиз 460805).

Примечание. Для .NET 4.0 и выше, если подраздел Full отсутствует, это значит, что данная версия Framework на компьютере не установлена.

С помощью следующей таблицы вы можете установить соответствие между номером релиза и версией .NET Framework 4.5 и выше.

Значение DWORD параметра Release Версия .NET Framework
378389 .NET Framework 4.5
378675 NET Framework 4.5.1 на Windows 8.1 / Windows Server 2012 R2
378758 .NET Framework 4.5.1 на Windows 8, Windows 7 SP1, Windows Vista SP2
379893 .NET Framework 4.5.2
393273 .NET Framework 4.6 на Windows 10
393297 .NET Framework 4.6
394254 .NET Framework 4.6.1 на Windows 10 November Update
394271 .NET Framework 4.6.1
394802 .NET Framework 4.6.2 на Windows 10 Anniversary Update
394806 .NET Framework 4.6.2
460798 .NET Framework 4.7 на Windows 10 Creators Update
460805 .NET Framework 4.7
461308 .NET Framework 4.7.1 на Windows 10 Fall Creators Update
461310 .NET Framework 4.7.1
461808 .NET Framework 4.7.2 на Windows 10 April 2018 Update
461814 .NET Framework 4.7.2

Проверка версии .Net Framework с помощью Powershell

Можно получить информацию об установленных версиях и релизах Framework с помощью PowerShell. Эту информацию также можно получить из реестра. Например, выведем информацию о текущем установелнном релизе .NET 4.x можно с помощью командлета Get-ItemProperty (подробнее о работе с записями реестра из PowerShell):

(Get-ItemProperty ‘HKLM:\SOFTWARE\Microsoft\NET Framework Setup\NDP\v4\Full’  -Name Release).Release

получаем версию net framework из powershell

Утилита .Net Version Detector

Существует сторонняя бесплатная утилита Asoft .Net Version Detector, с помощью которой можно в наглядном и удобном виде получить список установленные версий .NET Framework. Утилита качается с сайта разработчика (http://www.asoft.be/prod_netver.html) и не требует установки. В красивом окошке утилита выведет все установленные на компьютере версии .NET, а также максимальную доступную версию на данный момент.

Довольно удобно, что прямо в программе можно перейти на страницу загрузки различный версий .NET Framework, где можно скачать нужный пакет.

Утилита .Net Version Detector

Утилита CLRver.exe

В состав Microsoft Visual Studio входит отдельная утилита CLRver.exe, которая выводит отчет обо всех установленных версиях среды CLR на данном компьютере. Выполните команду CLRver.exe в командной строке и в консоли появится список установленных версии dotNet на компьютере.

Утилита CLRver.exe

Напоследок, в качестве полезной информации отметим, что в серверных ОС начиная с Windows Server 2012, все базовые версии .Net (3.5 и 4.5) является частью системы и устанавливаются в виде отдельного компонента (Установка .NET Framework 3.5 в Windows Server 2016, в Windows Server 2012 R2), а минорные (4.5.1, 4.5.2 и т.д.) устанавливаются уже в виде обновлений через Windows Update или WSUS.

Понравилась статья? Поделить с друзьями:
0 0 голоса
Рейтинг статьи
Подписаться
Уведомить о
guest

0 комментариев
Старые
Новые Популярные
Межтекстовые Отзывы
Посмотреть все комментарии
  • Где хранится бэкап windows
  • Realtek 8723be driver windows 10
  • Захват фото экрана windows 10
  • Драйвер для блютуз для windows 7 для гарнитуры
  • Windows script host 800a03ea