本文介绍了如何修复DNX / DNVM在Visual Studio 2015年?的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述

今天,我在Windows 7 64位系统安装了VS 2015年。主要是测试新的.NET的核心功能和等,并测试我创造了新的C#控制台应用程序(包)的解决方案,得到了这样的信息:

Today I installed VS 2015 on Windows 7 x64. Mainly to test new .Net Core features and etc. And for test I created new C# "Console Application (Package)" solution and got this message:

DNX S​​DK版本DNX-CLR-双赢x86.1.0.0-beta5的安装失败。该解决方案将使用DNX S​​DK版本DNX-CLR-双赢x86.1.0.0-beta5的本次会议。

我不能编译和调试项目。此外,在项目的属性时,我已经打开调试选项卡,然后VS崩溃了。

I can't compile and debug project. Also, when I have opened debug tab in project properties then VS crashed.

DNVM输出,当我打开的解决方案:

DNVM output when I opened solution:

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

任何想法如何解决这个问题?

Any ideas how to fix it?

另外,我有previously安装了VS 2015 preVIEW和DNX / DNVM分开。但我认为,我的VS 2015年安装前彻底清除它。莫非这在某种程度上影响了当前VS安装?

Also, I have previously installed VS 2015 Preview and DNX/DNVM separately. But I think, I completely removed it before VS 2015 installation. Could this somehow affects current VS installation?

推荐答案

这是一个已知的问题

ASP.NET 5:在Windows 7 SP1,DNX S​​DK不能在没有安装  PowerShell的3.0。

症状

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

When you create an ASP.NET 5 project, you receive the following error message:

DNX S​​DK版本DNX-CLR-双赢x86.1.0.0-beta5的安装失败。该  解决方案将使用DNX S​​DK版本DNX-CLR-双赢x86-1.0.0-beta5的为  本次会议

解决方法

要解决此问题,安装Windows PowerShell 3.0(或更高版本),然后再次尝试创建项目。要查看您当前的PS版,运行 $ PsVersionTable 命令(详细信息)。

To work around this issue, install Windows Powershell 3.0 (or higher) and try to create the project again. To see your current PS version, run $PsVersionTable command (details).

链接:

  • How要安装Windows PowerShell 4.0 。
  • Install PowerShell的3.0在Windows 7 。
  • How to Install Windows PowerShell 4.0.
  • Install PowerShell 3.0 on Windows 7.

这篇关于如何修复DNX / DNVM在Visual Studio 2015年?的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持!

09-21 03:55