尝试使用 VS 2012 打开我的 asp.net 4.5 MVC Web 应用程序时出错.Asp.net 尚未在服务器上注册 [英] Error when trying to open my asp.net 4.5 MVC web application using VS 2012. Asp.net has not been registered on the server

查看:28
本文介绍了尝试使用 VS 2012 打开我的 asp.net 4.5 MVC Web 应用程序时出错.Asp.net 尚未在服务器上注册的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述

我有一个 Windows Server 2012 R2 &Visual Studio Professional 2012.现在我用来开发一个 asp.net 4.5 mvc 4 web 应用程序,没有任何问题.但是现在当我尝试打开项目时,我会收到此错误:-

I have a Windows Server 2012 R2 & Visual Studio Professional 2012. now i use to develop an asp.net 4.5 mvc 4 web application without any problem. but now when i try to open the project i will get this error:-

如果我单击确定",则会出现此错误:-

if i click OK then this error:-

如果我点击确定,visual studio 将停止工作

if i click OK the visual studio will stop working

所以任何人都可以告诉这是怎么回事吗?

so can anyone adivce what is going on ??

这是打开/关闭窗口功能的样子:-

and here is how the Turn windows features on/off looks like:-

现在我做了这个修改,因为我在互联网上读到删除缓存可能会有帮助的帖子.所以我删除了这个文件夹:-

Now i did this modification, as i read on a post in the internet that deleting the cache might help. so i removed this folder:-

%LocalAppData%\Microsoft\VisualStudio\11.0\ComponentModelCache

然后我尝试打开 Visual Studio,我遇到了同样的 2 个错误,但是 Visual Studio 没有停止工作,我能够修改代码,我重建项目并运行它..所以不确定是什么是怎么回事?

then i tried to open the Visual Studio, and i got the same 2 errors, but the visual studio did not stop working, and i was able to modify the code i rebuild the project and run it.. so not sure what is going on ?

推荐答案

为了解决这个错误,你必须在你的系统中安装相关版本的.Net框架.

In order to resolve this error you have to install related version of .Net framework in your system.

如果没有安装请先安装IIS.

First install IIS if not installed.

然后运行以下命令:

C:\Windows\Microsoft.NET\Framework\v4.0.30319> aspnet_regiis -i

OR(取决于您的操作系统)

OR (Depens on your OS)

C:\Windows\Microsoft.NET\Framework64\v4.0.30319> aspnet_regiis -i

在 IIS 中,您的站点应该在池上运行,版本如下:.Net FrameWork v4.0.xxxxxx

And in IIS your site should run on pool with version like : .Net FrameWork v4.0.xxxxxx

以管理员身份打开您的解决方案

Open your solution as an Administrator

这篇关于尝试使用 VS 2012 打开我的 asp.net 4.5 MVC Web 应用程序时出错.Asp.net 尚未在服务器上注册的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!

查看全文
登录 关闭
扫码关注1秒登录
发送“验证码”获取 | 15天全站免登陆