.NET Framework 3.5中有哪些有用的新ASP.NET功能?

时间:2020-12-27 17:02:22

I've kept up to date with new features in the C# language as it's moved from version 1 through version 3. I haven't done such a good job keeping up to date with ASP.NET. I feel like some of the post version 1 features are not so good (e.g. the AJAX framework) or are just not that useful to me (e.g. the membership framework). Can anyone recommend any new killer ASP.NET features that might have gone unnoticed?

我一直在使用C#语言中的新功能,因为它从版本1移动到版本3.我没有做好与ASP.NET保持同步的好工作。我觉得一些后期版本1的功能不是那么好(例如AJAX框架)或者对我没有用(例如成员资格框架)。任何人都可以推荐任何可能未被注意到的新的杀手级ASP.NET功能吗?

13 个解决方案

#1


8  

For ASP.NET, you have a lot of improvements:

对于ASP.NET,您有很多改进:

  • split view (code and design)
  • 拆分视图(代码和设计)

  • faster switching between code and design view
  • 更快地在代码和设计视图之间切换

  • embedded master pages (one master page in another)
  • 嵌入式母版页(另一个母版页)

  • javascript debugging

Anyway most of the useful stuff are really in the meat of the language, and for .NET 3.5 the new language features for C# 3.0 will be (and yes, I find ALL of them useful)

无论如何,大多数有用的东西都是真正的语言,对于.NET 3.5,C#3.0的新语言功能将是(并且是的,我发现它们都很有用)

  • anonymous objects
  • automatic properties
  • object initializers
  • collection initializers (inline initialization for collections)
  • 集合初始值设定项(集合的内联初始化)

  • implicit typing (var keyword)
  • 隐式类型(var关键字)

  • lambda expressions
  • LINQ
  • Extension methods

I might have forgotten a few, but I think this is about most of the new cool and useful stuff.

我可能已经忘记了一些,但我认为这是关于大多数新的酷和有用的东西。

#2


5  

Check out the MVC framework which is built ontop of 3.5. Big improvement over the traditional webforms model.

查看构建在3.5之上的MVC框架。与传统的webforms模型相比有了很大的改进。

#3


3  

I'm still learning ASP.net so I can't tell you exactly, but if you look through http://www.asp.net/learn/ you'll probably find a few new gems, there's even a 3.5 section.

我还在学习ASP.net,所以我无法准确地告诉你,但如果你浏览http://www.asp.net/learn/,你可能会发现一些新的宝石,甚至还有3.5节。

#4


2  

ListView and its friend DataPager are probably worth looking at, but they're hardly "Killer" features.

ListView及其好友DataPager可能值得一看,但它们几乎不是“杀手”功能。

Things outside of ASP.NET specifically (LINQ, for example) are probably more likely to be get the "Killer" commendation.

ASP.NET之外的事情(例如LINQ)可能更有可能得到“杀手”的称赞。

#5


1  

Its the MVC framework. Without 3.5, there is no MVC. Without MVC, ASP.NET is a PITA.

它的MVC框架。没有3.5,没有MVC。没有MVC,ASP.NET就是PITA。

#6


1  

Master Pages

(of course, these are in there from version 2.0)

(当然,这些都是2.0版本)

Nested master pages are new in 3.5. I haven't used them yet, but I can only imagine they could turn into a hidious nightmare if not used very carefully.

嵌套母版页是3.5中的新内容。我还没有使用它们,但我只能想象如果不仔细使用它们会变成阴险的噩梦。

You only have to look at the order in which the events are fired in a page that uses a master page to think 'urgh'.

您只需要在使用母版页来思考'urgh'的页面中查看触发事件的顺序。

#7


1  

I don't think the MVC Framework is quite ready for prime time yet

我认为MVC框架尚未准备好迎接黄金时段

Just an FYI, this site is built in MVC. I also have 2 apps in production on mvc, I would argue that its definitely ready for prime time.

仅仅是一个FYI,这个站点是用MVC构建的。我在mvc上也有2个应用程序正在制作中,我认为它绝对准备好迎接黄金时段。

#8


1  

@IainMH Nested Master Pages were always supported by ASP.NET, just not by the designer.

@IainMH嵌套的主页总是由ASP.NET支持,而不是由设计者支持。

#9


1  

As others have said, there's a good list at www.asp.net/learn. I think the biggest ASP.NET specific changes are:

正如其他人所说,在www.asp.net/learn上有一个很好的列表。我认为ASP.NET最具体的变化是:

  • Official ASP.NET AJAX integration
  • 官方ASP.NET AJAX集成

  • ListView (much better than the GridView / DataView in that they let you write out clean HTML)
  • ListView(比GridView / DataView要好得多,因为它们可以让你写出干净的HTML)

  • Big improvements to the IDE for CSS / HTML editing
  • 用于CSS / HTML编辑的IDE的重大改进

  • Javascript debugging

Note that ASP.NET MVC is not released yet, and was definitely not included with ASP.NET 3.5.

请注意,ASP.NET MVC尚未发布,并且绝对不包含在ASP.NET 3.5中。

#10


1  

Here's a brief list of my favourites:

这是我最喜欢的简短列表:

  • LINQ
  • Extension Methods
  • Lambda Methods

And I don't actually use ASP.NET, but ASP.NET AJAX is now included in 3.5 too and ASP.NET MVC is included in 3.5 SP1.

我实际上并不使用ASP.NET,但ASP.NET AJAX现在也包含在3.5中,而ASP.NET MVC包含在3.5 SP1中。

#11


0  

I don't think the MVC Framework is quite ready for prime time yet, though I definitely plan to use it sometime next year. I love the clean URLs, clean XHTML (web forms can really spew out some nasty HTML) and the ability to create controller actions with no associated view.

我认为MVC框架尚未准备好迎接黄金时段,但我绝对计划在明年的某个时候使用它。我喜欢干净的URL,干净的XHTML(Web表单可以真正喷出一些讨厌的HTML)以及创建没有关联视图的控制器操作的能力。

I've been using Master Pages since they were released and they've been a big help. I do really dislike the way the master pages add the nasty prefixes to the control IDs. It makes for some ugly CSS. I think the MVC Framework may eliminate this problem though.

我一直在使用Master Pages,因为它们已经发布,它们已经得到了很大的帮助。我真的不喜欢母版页添加令人讨厌的前缀到控件ID的方式。这使得一些丑陋的CSS。我认为MVC框架可能会消除这个问题。

Any other killer features?

还有其他杀手锏吗?

#12


0  

The split design/code view is pretty cool. It's not perfect yet, but it's pretty cool. Also editing in the design view now edits your css there and then.

拆分设计/代码视图非常酷。它还不完美,但它非常酷。现在,在设计视图中进行编辑也可以在那里编辑css。

#13


0  

also Dynamic Data have to be consider

还必须考虑动态数据

#1


8  

For ASP.NET, you have a lot of improvements:

对于ASP.NET,您有很多改进:

  • split view (code and design)
  • 拆分视图(代码和设计)

  • faster switching between code and design view
  • 更快地在代码和设计视图之间切换

  • embedded master pages (one master page in another)
  • 嵌入式母版页(另一个母版页)

  • javascript debugging

Anyway most of the useful stuff are really in the meat of the language, and for .NET 3.5 the new language features for C# 3.0 will be (and yes, I find ALL of them useful)

无论如何,大多数有用的东西都是真正的语言,对于.NET 3.5,C#3.0的新语言功能将是(并且是的,我发现它们都很有用)

  • anonymous objects
  • automatic properties
  • object initializers
  • collection initializers (inline initialization for collections)
  • 集合初始值设定项(集合的内联初始化)

  • implicit typing (var keyword)
  • 隐式类型(var关键字)

  • lambda expressions
  • LINQ
  • Extension methods

I might have forgotten a few, but I think this is about most of the new cool and useful stuff.

我可能已经忘记了一些,但我认为这是关于大多数新的酷和有用的东西。

#2


5  

Check out the MVC framework which is built ontop of 3.5. Big improvement over the traditional webforms model.

查看构建在3.5之上的MVC框架。与传统的webforms模型相比有了很大的改进。

#3


3  

I'm still learning ASP.net so I can't tell you exactly, but if you look through http://www.asp.net/learn/ you'll probably find a few new gems, there's even a 3.5 section.

我还在学习ASP.net,所以我无法准确地告诉你,但如果你浏览http://www.asp.net/learn/,你可能会发现一些新的宝石,甚至还有3.5节。

#4


2  

ListView and its friend DataPager are probably worth looking at, but they're hardly "Killer" features.

ListView及其好友DataPager可能值得一看,但它们几乎不是“杀手”功能。

Things outside of ASP.NET specifically (LINQ, for example) are probably more likely to be get the "Killer" commendation.

ASP.NET之外的事情(例如LINQ)可能更有可能得到“杀手”的称赞。

#5


1  

Its the MVC framework. Without 3.5, there is no MVC. Without MVC, ASP.NET is a PITA.

它的MVC框架。没有3.5,没有MVC。没有MVC,ASP.NET就是PITA。

#6


1  

Master Pages

(of course, these are in there from version 2.0)

(当然,这些都是2.0版本)

Nested master pages are new in 3.5. I haven't used them yet, but I can only imagine they could turn into a hidious nightmare if not used very carefully.

嵌套母版页是3.5中的新内容。我还没有使用它们,但我只能想象如果不仔细使用它们会变成阴险的噩梦。

You only have to look at the order in which the events are fired in a page that uses a master page to think 'urgh'.

您只需要在使用母版页来思考'urgh'的页面中查看触发事件的顺序。

#7


1  

I don't think the MVC Framework is quite ready for prime time yet

我认为MVC框架尚未准备好迎接黄金时段

Just an FYI, this site is built in MVC. I also have 2 apps in production on mvc, I would argue that its definitely ready for prime time.

仅仅是一个FYI,这个站点是用MVC构建的。我在mvc上也有2个应用程序正在制作中,我认为它绝对准备好迎接黄金时段。

#8


1  

@IainMH Nested Master Pages were always supported by ASP.NET, just not by the designer.

@IainMH嵌套的主页总是由ASP.NET支持,而不是由设计者支持。

#9


1  

As others have said, there's a good list at www.asp.net/learn. I think the biggest ASP.NET specific changes are:

正如其他人所说,在www.asp.net/learn上有一个很好的列表。我认为ASP.NET最具体的变化是:

  • Official ASP.NET AJAX integration
  • 官方ASP.NET AJAX集成

  • ListView (much better than the GridView / DataView in that they let you write out clean HTML)
  • ListView(比GridView / DataView要好得多,因为它们可以让你写出干净的HTML)

  • Big improvements to the IDE for CSS / HTML editing
  • 用于CSS / HTML编辑的IDE的重大改进

  • Javascript debugging

Note that ASP.NET MVC is not released yet, and was definitely not included with ASP.NET 3.5.

请注意,ASP.NET MVC尚未发布,并且绝对不包含在ASP.NET 3.5中。

#10


1  

Here's a brief list of my favourites:

这是我最喜欢的简短列表:

  • LINQ
  • Extension Methods
  • Lambda Methods

And I don't actually use ASP.NET, but ASP.NET AJAX is now included in 3.5 too and ASP.NET MVC is included in 3.5 SP1.

我实际上并不使用ASP.NET,但ASP.NET AJAX现在也包含在3.5中,而ASP.NET MVC包含在3.5 SP1中。

#11


0  

I don't think the MVC Framework is quite ready for prime time yet, though I definitely plan to use it sometime next year. I love the clean URLs, clean XHTML (web forms can really spew out some nasty HTML) and the ability to create controller actions with no associated view.

我认为MVC框架尚未准备好迎接黄金时段,但我绝对计划在明年的某个时候使用它。我喜欢干净的URL,干净的XHTML(Web表单可以真正喷出一些讨厌的HTML)以及创建没有关联视图的控制器操作的能力。

I've been using Master Pages since they were released and they've been a big help. I do really dislike the way the master pages add the nasty prefixes to the control IDs. It makes for some ugly CSS. I think the MVC Framework may eliminate this problem though.

我一直在使用Master Pages,因为它们已经发布,它们已经得到了很大的帮助。我真的不喜欢母版页添加令人讨厌的前缀到控件ID的方式。这使得一些丑陋的CSS。我认为MVC框架可能会消除这个问题。

Any other killer features?

还有其他杀手锏吗?

#12


0  

The split design/code view is pretty cool. It's not perfect yet, but it's pretty cool. Also editing in the design view now edits your css there and then.

拆分设计/代码视图非常酷。它还不完美,但它非常酷。现在,在设计视图中进行编辑也可以在那里编辑css。

#13


0  

also Dynamic Data have to be consider

还必须考虑动态数据