gpt4 book ai didi

.net - 如何修复 Visual Studio 2015 中的 DNX/DNVM?

转载 作者:行者123 更新时间:2023-12-03 05:46:11 27 4
gpt4 key购买 nike

今天我在 Windows 7 x64 上安装了 VS 2015。主要是为了测试新的 .Net Core 功能等。为了测试,我创建了新的 C#“控制台应用程序(包)”解决方案并收到以下消息:

DNX SDK version 'dnx-clr-win-x86.1.0.0-beta5' failed to install. The solution will use DNX SDK version ‘dnx-clr-win-x86.1.0.0-beta5’ for this session.

我无法编译和调试项目。另外,当我在项目属性中打开调试选项卡时,VS 崩溃了。

打开解决方案时 DNVM 输出:

Invoke-Command : The term 'x86' is not recognized as the name of a cmdlet, func
tion, script file, or operable program. Check the spelling of the name, or if a
path was included, verify that the path is correct and try again.
C:\Program Files\Microsoft DNX\Dnvm\dnvm.ps1:1451 ????:27
+ Invoke-Command <<<< ([ScriptBlock]::Create("dnvm-$cmd $cmdargs")
)
+ CategoryInfo : ObjectNotFound: (x86:String) [Invoke-Command], C
ommandNotFoundException
+ FullyQualifiedErrorId : CommandNotFoundException,Microsoft.PowerShell.Co
mmands.InvokeCommandCommand

Invoke-Command : The term 'x86' is not recognized as the name of a cmdlet, func
tion, script file, or operable program. Check the spelling of the name, or if a
path was included, verify that the path is correct and try again.
C:\Program Files\Microsoft DNX\Dnvm\dnvm.ps1:1451 ????:27
+ Invoke-Command <<<< ([ScriptBlock]::Create("dnvm-$cmd $cmdargs")
)
+ CategoryInfo : ObjectNotFound: (x86:String) [Invoke-Command], C
ommandNotFoundException
+ FullyQualifiedErrorId : CommandNotFoundException,Microsoft.PowerShell.Co
mmands.InvokeCommandCommand

Invoke-Command : The term 'x86' is not recognized as the name of a cmdlet, func
tion, script file, or operable program. Check the spelling of the name, or if a
path was included, verify that the path is correct and try again.
C:\Program Files\Microsoft DNX\Dnvm\dnvm.ps1:1451 ????:27
+ Invoke-Command <<<< ([ScriptBlock]::Create("dnvm-$cmd $cmdargs")
)
+ CategoryInfo : ObjectNotFound: (x86:String) [Invoke-Command], C
ommandNotFoundException
+ FullyQualifiedErrorId : CommandNotFoundException,Microsoft.PowerShell.Co
mmands.InvokeCommandCommand

有什么解决办法吗?

另外,我之前已经分别安装了 VS 2015 Preview 和 DNX/DNVM。但我想,我在安装VS 2015之前完全删除了它。这会以某种方式影响当前的 VS 安装吗?

最佳答案

这是一个known issue .

ASP.NET 5: On Windows 7 SP1, DNX SDK cannot be installed without Powershell 3.0.

症状

当您创建 ASP.NET 5 项目时,您会收到以下错误消息:

DNX SDK version 'dnx-clr-win-x86.1.0.0-beta5' failed to install. The solution will use DNX SDK version 'dnx-clr-win-x86-1.0.0-beta5' for this session

解决方法

要解决此问题,请安装 Windows Powershell 3.0(或更高版本)并尝试再次创建项目。要查看当前的 PS 版本,请运行 $PsVersionTable 命令 ( details )。

链接:

关于.net - 如何修复 Visual Studio 2015 中的 DNX/DNVM?,我们在Stack Overflow上找到一个类似的问题: https://stackoverflow.com/questions/31546274/

27 4 0
Copyright 2021 - 2024 cfsdn All Rights Reserved 蜀ICP备2022000587号
广告合作:1813099741@qq.com 6ren.com