开发者

SharePoint Web part vs ASP.NET web part

Can some one give me the difference between a SharePoint web part and an开发者_开发技巧 ASP.NET web part. I found very little information describing the differences.

Thanks in advance.


MSDN - Choosing Between ASP.NET 2.0 Web Parts and Windows SharePoint Services 3.0 Web Parts

You should create ASP.NET 2.0 Web Parts whenever you can. However, there are a few exceptions where using SharePoint-based Web Parts might offer advantages.. The following table provides a decision matrix to help you choose the best option depending on your business needs.

Create a custom ASP.NET 2.0 Web Part

  • For most business needs.

  • To distribute your Web Part to sites that run ASP.NET 2.0 or SharePoint sites.

  • When you want to reuse one or more Web Parts created for ASP.NET 2.0 sites on SharePoint sites.

  • To use data or functionality provided by Windows SharePoint Services 3.0. For example, you are creating a a Web Part that works with site or list data.

Create a SharePoint-based Web Part

  • When you want to migrate a set of Web Parts using the SharePoint-based Web Part infrastructure to Windows SharePoint Services 3.0.

  • To create cross page connections.

  • To create connections between Web Parts that are outside of a Web Part zone.

  • To work with client-side connections (Web Part Page Services Component).

  • To use a data-caching infrastructure that allows caching to the content database.


As far as i got, SharePoint WebPart overrides ASP.NET WebPart

  1. to to persist its data inside the content database of SharePoint Foundation

  2. you can design for and use an ASP.NET Web Part in SharePoint, but not vice versa.

  3. SPF WebParts supports backward compatibility, cross-page connections, conns between WebParts that are outside of a zone, client-side connections (Web Part Pages Services Component), data caching (incl. to database)

  4. they use differing WebPartManager (e.g. SPWebPartManager) and WebPartZone objects, so you can't easy copy WebParts Pages from ASP.NET to SharePoint, but rather export WebParts

Most of that you find on ...

http://msdn.microsoft.com/en-us/library/microsoft.sharepoint.webpartpages.webpart.aspx

http://msdn.microsoft.com/en-us/library/ms415560.aspx

0

上一篇:

下一篇:

精彩评论

暂无评论...
验证码 换一张
取 消

最新问答

问答排行榜