简体   繁体   English

将ASP转换为ASP.NET

[英]CONVERT ASP TO ASP.NET

Which is the best way to convert a .asp page to .aspx? 将.asp页转换为.aspx的最佳方法是哪一种? Classic asp to asp.net. asp.net的经典asp。 I'm trying to avoid rewriting all the pages from scratch. 我试图避免从头开始重写所有页面。

Thanks 谢谢

I think it's a completely different language and you really can't avoid doing everything from scracth. 我认为这是一门完全不同的语言,您真的无法避免因为拼写而做任何事情。 I think that any solution other than starting all over would take just as much time and headache than starting from scratch. 我认为,除了从头开始之外,任何其他解决方案都将花费与从头开始一样多的时间和头痛。

It really depends on a lot of things. 这确实取决于很多事情。 Mainly, how complicated the page is, and what it does. 主要是页面的复杂程度及其作用。 You will need to be a little more specific in your question, but there really isn't any single "one shot" solution. 您将需要对问题进行更具体的说明,但是实际上并没有任何单一的“一次性”解决方案。

My first shot at asp.net was migrating an asp application and there was and still is no straightforward migration path. 我在asp.net上的第一枪是迁移一个ASP应用程序,现在有,现在仍然没有简单的迁移路径。 The best that we found was so split the application up into functional areas then migrate each area - effectively running two apps with a bridge inbetween. 我们发现最好的办法是将应用程序划分为功能区域,然后迁移每个区域-有效地运行两个应用程序,并在两者之间建立桥梁。

I always thought that ASP.Net was misnamed as it made it look like an upgrade to classic ASP which really don't believe it is. 我一直以为ASP.Net的命名错误是因为它看起来像是对经典ASP的升级,但实际上不相信它。 ASP.Net is more like an attempt to bring windows style programming to the web, abstracting away the stateless nature of the http request - certainly in it's webforms incarnation ASP.Net更像是将Windows风格的编程引入网络的尝试,抽象了http请求的无状态本质-当然是在Webforms化身中

If you are determined for a classic ASP style app you could include all the code on one page forgetting the page behind model though that would be unusual. 如果您确定要使用经典的ASP风格的应用程序,则可以将所有代码包含在一页上,而忘记模型背后的页面,尽管那是不寻常的。 If you can make decisions about the technology used you could consider MVC as conceptually at least it has more in common with ASP than the webforms. 如果您可以对所使用的技术做出决定,则可以认为MVC在概念上至少与ASP具有比Web表单更多的共同点。 MVC admits it's a web app (like ASP) whereas webforms prefer to hide that fact under the covers. MVC承认它是一个Web应用程序(如ASP),而Webforms则更倾向于将事实隐藏在幕后。

声明:本站的技术帖子网页,遵循CC BY-SA 4.0协议,如果您需要转载,请注明本站网址或者原文地址。任何问题请咨询:yoyou2525@163.com.

 
粤ICP备18138465号  © 2020-2024 STACKOOM.COM