Install the .NET Framework 3.5 Feature using PowerShell

Started by ciba, May 16, 2022, 02:43 PM

Previous topic - Next topic

ciba

The following commands must be executed within a PowerShell that was started as an
administrator.
You can verify if the .NET Framework 3.5 is already installed by running the following PowerShell
command:

PS> Get-WindowsFeature -Name "NET-Framework-Core"
If the .NET Framework 3.5 is not installed, you will receive an output like the following:

Display Name Name Install State
------------
---- -------------
[ ] .NET Framework 3.5 (includes .NET 2.0 and 3.0) NETFramework-Core Removed

To install the .NET Framework 3.5 Windows feature, you must run the following command:

PS> Install-WindowsFeature -Name "NET-Framework-Core" -Source "D:\Sources\SxS"
After the command has finished, you will receive an output like this:

Success Restart Needed Exit Code Feature Result
------- -------------- --------- --------------
True No Success {.NET Framework 3.5
(includes .NET 2.0 and...

If you run the following command again, the column Install State should show Installed for
the .NET Framework 3.5 (includes .NET 2.0 and 3.0) feature:

PS> Get-WindowsFeature -Name "NET-Framework-Core"
Display Name
Name Install State
------------
---- -------------
[X] .NET Framework 3.5 (includes .NET 2.0 and 3.0) NETFramework-Core Installed