我想知道您使用ASP.NET webparts作为网站中可重用组件的经验。
你找到它有用吗? 你有没有发现任何严重的问题? 你会推荐在任何asp.net项目中使用吗?
您希望强调的任何最佳做法或提示。
您是否会建议使用webpart作为asp.net门户网站设计的一部分,或者我们将您的设计作为基础,以我们优秀的旧UserControl为中心。
这个输入将帮助我决定我正在开发的asp.net应用程序。
如果您需要更多说明,请留下评论。
I would like to know your experience with ASP.NET webparts as a reusable component in your website.
How useful did you find it? Did you find any serious issues with it? Would you recommend it using in any asp.net project?
Any best practices or tips you would like to highlight with respect to this.
Would you recommend using webparts as part of the asp.net portal design or would our center your design around our good old UserControl as the foundation.
This input would help me make my decision for an asp.net application that I am developing.
In case you require more clarification please do leave comments.
最满意答案
WebParts优于UserControls的优点:
支持内置的用户可编辑属性和个性化 可定制的编辑器部件 可定制的标准WebPart菜单 WebPartZones之间的Drag'n'Drop WebParts 支持WebParts之间的连接,对主/详细视图,过滤器等非常有用 可以加载UserControls缺点:
资源使用率更高 Visual Studio目前没有WebParts的设计器支持就像提到的ocdecio一样,ASP.NET MVC现在可能是一个更好的选择,至少在SharePoint世界之外,WebParts非常重要。
编辑:
有关ASP.NET 2.0 WebParts的概述,您可能需要查看:
在ASP.Net 2.0中使用WebParts并使用用户控件和自定义Web部件个性化您的门户
Advantages of WebParts over UserControls:
Support for user editable properties and personalization built in Customizable Editor Parts Customizable standard WebPart menus Drag'n'Drop WebParts between WebPartZones Support for connections between WebParts, useful for master/detail views, filters, and more Can load UserControlsDisadvantages:
Higher Resource Usage Visual Studio currently does not have designer support for WebPartsLike ocdecio mentioned, ASP.NET MVC would probably be a better choice nowadays, at least outside of the SharePoint world, where WebParts are very important.
EDIT:
For an overview of ASP.NET 2.0 WebParts, you may want to look at:
Using WebParts in ASP.Net 2.0 and Personalize Your Portal with User Controls and Custom Web Parts
更多推荐
发布评论