Upgrading from ASP.NET 1.1 to 2.0

ASTM D4583-21(2025).pdf ASTM D4583-21(2025) 立即下载
  Recently I'm working on the stuff that upgrading a ASP.NET 1.1 project to ASP.NET 2.0(of course, I mean visual studio 2005 beta 2).
  Before starting this stuff, my colleague in U.S and I both think it should be a very simple work, and I actually think it just need me to run a wizard and click some "Next" button and then we will get a new version on 2.0.
  Life is not eay, really. it was bored when I found a lot of errors pop up during my compilation after upgrading even there's no any error during upgrading. You know, I cann't believe my eyes when so many errors pop up, it seems that these errors are laughing at him and tell me how stupid I am. Cruel reality.
  In the next several days, I still think there will be a simply trick or simply switch somewhere I don't know, and I can quickly erase these boring errors if I know them. I cann't believe I must do some coding work after upgrading. It's unfair!
  After several days' research and enduring the angry mood, at last, I give up. I acccepted the reality that the trick/switch doesn't exit, I must do some coding work for upgrading. And I want to share these experience to you:
  1. The Stand Alone(SA) class in one project will be moved to the App_data directory, it's a special directory, files in this directory will belong to a new assembly, not the same assembly of current project, and ASP.NET refer the new assembly automatially so the objects in the root project directory can access the objects in App_data directory, but not reverse, so if you want to visit the objects in the root project directory from the objects in App_data directory, you must do some code work, basically you should add an abstract class(stub) in the App_data directory, the properties and methods you need to access should be defined abstractly in this abstract class, and then, the object in root dir you want to access should be changed to inherited from the new abstract class. of course, if the object in root dir is inherited from certain base class already(like System.Web.UI.Usercontrol), let the abstract class inherited from it too. OK, now you can use lay-bind technic to load the object in root dir and cast it to the abstract class type. a little complex, right? here is the example code in the object in App_code directory:
  BaseClass baseClass = (BaseClass)Page.LoadControls("PageInRootDir.aspx");

  2. Sometimes objects in several ascx files cann't access the objects in aspx files. I wrote a simple project in 2003, and convert it to 2005, this condition didn't happen. but in my working project it really happened. I don't know why, but I know how to fix it: it semms that these ascx files are compiled to a assembly just like the assembly with App_data dir, so what we need to do is add an interface or abstract class in one of the ascx file, and let the object what we need to visit in aspx files implement the interface or inherited form the abstract class, similiar with the first condition.

  3. Is there an object its name is "Profile" in your project? It's ok in 2003, but please change its name in 2005, it seems the word is a new keyword in 2005, and if you keep it, you cann't pass the compilation.

  That's it, I will be glad if my experience help you feel a little easy converting project from 1.1 to 2.0. and let me know if you have any suggestions.

技术转移机构如何高效评估技术成果的价值?.docx 技术转移机构如何高效评估技术成果的价值? 立即下载

相关推荐

Upgrading an ASP.NET MVC 2 Project to ASP.NET MVC 3 Tools Update

ASP.NET MVC 3 can be installed side by side with ASP.NET MVC 2 on the same computer, which gives you flexibility in choosing when to upgrade an ASP.NET MVC 2 application to ASP.NET MVC 3. To manually...

weixin_30788239的博客 108

[转]Upgrading to Async with Entity Framework, MVC, OData AsyncEntitySetController, Kendo UI, Glimpse ...

本文转自:http://www.tuicool.com/articles/BBVr6z Thanks to everyone for allowing us to give back to the .NET community, we released v1.0 of theGeneric Unit of Work and Repository Frameworkfor four weeks...

weixin_30652879的博客 119

How to fix intellisense issues after upgrading to ASP.NET Ajax 1.0 RC

Many people reported issues after upgrade from Atlas/Ajax Beta or CTP to the most recent RC build (1.0.61025). Typical symptoms are: 1. UpdatePanel, ScriptManager and other ASP.NET Ajax elements are s...

caobihole 90

收藏:Upgrading VS 2005 Web Site Projects to be VS 2005 Web Application Projects

http://webproject.scottgu.com/CSharp/Migration2/Migration2.aspx http://msdn2.microsoft.com/en-us/library/aa983476(VS.80).aspx Upgrading VS 2005 Web Site Projects to be VS 2005 Web Application ...

weixin_30455067的博客 101

My namespace disappear in ASP.NET 2(beta2)?

   When you create your first ASP.NET 2.0 Web Page. You may say:"Oh!", theres no default namespace in your code-behind cs file? OK, lets add one, we think every object should be in one certain names

daidaoke2001的专栏 1119

JavaScript operators( from Javascrip: The definitive guide, 4th guide)

Table 5-1. JavaScript operators PAOperatorOperand type(s)Operation performed15L.object, identifierProperty access L[]array, integerArray index L( )function, argumentsFunction call Rnewconstructor call

daidaoke2001的专栏 1086

How does the certain version of a certain brower support the JavaScript Standard?(come from Javascript:The definitive guide, 4th

Table 1-2. Client-side JavaScript features by browser BrowserLanguageDOM capabilitiesNetscape 2JavaScript 1.0Form manipulation Netscape 3JavaScript 1.1Image rollovers Netscape 4JavaScript 1.2DHTML wit

daidaoke2001的专栏 1065

Uncle Chutney's ASP.NET articles

 The articles about ASP.NET written by Uncle Chutney are great, he explains common troubles and questions lot of programmers like me encounter and worried about, explian complex things using simply an

daidaoke2001的专栏 1027

the difference between ClientID and ID of web control

  Basically, The ID of web control should be used on serverprogramming, and the ClientID should be used on Client, pretty basic.if you want to use the ID of web control on Client, you will find it

daidaoke2001的专栏 988

C++ 智能指针:auto_ptr / unique_ptr / shared_ptr / weak_ptr 原理与使用

智能指针拷贝核心原理适用场景auto_ptr转移所有权废弃不要用unique_ptr❌禁止拷贝 ✅支持 move独占资源独占所有权,默认首选shared_ptr✅支持拷贝引用计数需要多指针共享资源weak_ptr不持有资源不增加计数解决 shared_ptr 循环引用编码建议:优先用unique_ptr;确需共享再选shared_ptr;存在双向引用 / 环形结构,配合weak_ptr。

dajuc的博客 292
上一篇: the difference between ClientID and ID of web control
下一篇: My namespace disappear in ASP.NET 2(beta2)?
daidaoke2001
博客等级 码龄25年 1粉丝 26原创
评论
成就一亿技术人!
拼手气红包6.0元
还能输入1000个字符
 
 条评论被折叠 查看
添加红包

请填写红包祝福语或标题

红包个数最小为10个

红包金额最低5元

当前余额3.43前往充值 >
需支付:10.00
成就一亿技术人!
领取后你会自动成为博主和红包主的粉丝 规则
hope_wisdom
发出的红包
实付
使用余额支付
点击重新获取
扫码支付
钱包余额 0

抵扣说明:

1.余额是钱包充值的虚拟货币,按照1:1的比例进行支付金额的抵扣。
2.余额无法直接购买下载,可以购买VIP、付费专栏及课程。

余额充值