将VS2003项目升级到VS2005后重新映射localhost [英] Repointing localhost after upgrading VS2003 project to VS2005

查看:85
本文介绍了将VS2003项目升级到VS2005后重新映射localhost的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述

过去几年我一直是VB.net Winforms开发人员,现在我需要在我的第一个Web应用程序上工作。几年前,我参加了一系列为期一天的ASP.Net课程,但直到现在我还没有机会将这些知识付诸实践。我的任务是升级/重写现有的VS2003 Web项目。写它的人不再适用于我们公司,但我确实有源代码。我只有VS2005,所以我一直在尝试将应用程序升级到该版本,我遇到了一些问题。当我在VS2005中打开解决方案时,它会打开升级向导。当它完成时,它说它已经升级了解决方案,但它给我一个错误说:无法打开Web''http:// localhost / MyApp''。无法在端口80上的localhost上找到Web服务器。如何解决此问题,使其指向正确的Web服务器?此外,由于我是网络应用程序的新手,我想知道是否有人可以指出一些好的ASP.Net教程,所以在点击这个项目之前我可以稍微了解一下。在这方面的任何帮助将不胜感激。

I’ve been a VB.net Winforms developer the past few years and I now have a need to work on my 1st Web app. A couple of years ago I took a series of 1 day courses on ASP.Net but until now I haven’t had a chance to put that knowledge to work. I’ve been tasked to upgrade/rewrite an existing VS2003 Web project. The person that wrote it no longer works for our company but I do have the source code. I only have VS2005 so I have been trying to upgrade the app to that version and I’m having some issues. When I open up the Solution in VS2005, it brings up the upgrade wizard. When it finishes, it says it has upgraded the solution but it gives me an error saying: Unable to open the Web ''http://localhost/MyApp''. Could not find a Web server at ''localhost'' on port 80. How do I fix this so it points to the right web server? Also, since I am new to web apps, I am wondering if someone could point me to a few good ASP.Net tutorials so I can brush up on things a bit before hitting this project. Any help in this area would be appreciated.

推荐答案

很难看到你在没有看到所有步骤的情况下搞砸了。通常,运行有效的ASP.NET应用程序不会产生任何问题。



我建议如下:从头开始创建一个简单的Web站点。 URI http:// localhost用于在与Visual Studio捆绑在一起的HTTP服务器下的开发计算机上进行测试/调试。当您从头开始执行所有操作并第一次点击运行时,将启动此开发HTTP服务器。您将看到一个窗口,您可以在其中选择首先加载的URI,即项目中可用的URI。当您进行基本练习时,您可能会看到如何恢复您的遗留项目。如果你愿意,你可以运行任何其他HTTP服务器,但它不会让你调试你的服务器端代码,它必须支持ASP.NET。







我的其他建议:从遗留项目中删除所有非纯源代码。从头开始构建并启动它。当然,无论你做什么工作,都应该清楚地了解什么是源代码,什么不是。删除所有obj,bin,* .user,* .ncb...有时,项目清除操作(从项目菜单或解决方案资源管理器)有帮助,但在启动Visual Studio之前手动清理它是最确定的方法。



[结束编辑]



学习ASP.NET?我认为没有比从 http://www.asp.net/get-started [ ^ ]。



祝你好运,

-SA
It''s hard to see where did you screw up this without seeing all your steps. Usually, running a valid ASP.NET application presents no problems.

I would advise the following: create a simple Web site from scratch. The URI http://localhost is used for testing/debugging on an development computer under the HTTP server bundled with Visual Studio. When you do everything from scratch and hit "Run" for the very first time, this "development HTTP server" is started. You will get a window where you can choose a URI to load first, one of those available in your project. When you do the basic exercises, you might be able to see how to revive your legacy project. If you wish, you can run any other HTTP server, but it won''t let you debug your server-side code and it has to support ASP.NET.



My other advice: from your legacy project, remove everything which is not a pure source code. Build and start it from scratch. Naturally, you should clear understand what is source code and what''s not, no matter what work do you do. Remove all "obj", "bin", "*.user", "*.ncb"… Sometimes, project clear operations (from project menu or Solution Explorer) helps, but cleaning it manually before even starting Visual Studio is the most sure method.

[END EDIT]

Learning ASP.NET? I think there is nothing better than starting from http://www.asp.net/get-started[^].

Good luck,
—SA


这篇关于将VS2003项目升级到VS2005后重新映射localhost的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!

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