原文連接:https://www.muhanxue.com/essays/2017/04/3736598.htmlhtml
使用 Windows Server 2012 R2 或 Windows Server 2016系統,發如今安裝 .net 3.5.1 時報錯,報錯內容以下:windows
找不到安裝源文件。spa
能夠經過以下 PowerShell 腳本進行安裝:.net
輸入以下腳本後回車執行:code
Set-ItemProperty -Path 'HKLM:\SOFTWARE\Policies\Microsoft\Windows\WindowsUpdate\AU' -Name UseWUServer -Value 0
Restart-Service -Name wuauserv
Install-WindowsFeature Net-Framework-Core
Set-ItemProperty -Path 'HKLM:\SOFTWARE\Policies\Microsoft\Windows\WindowsUpdate\AU' -Name UseWUServer -Value 1
Restart-Service -Name wuauserv
若是未順利執行,請檢查 「windows update 服務」是否能正常啓動htm