1 / 25

Extending SharePoint through Web Parts and ASP.NET

Extending SharePoint through Web Parts and ASP.NET. 최승현 대리 (shchoi@microsoft.com) 한국마이크로소프트. Built on .Net Framework. Windows SharePoint Server (WSS) v2 is built on top of the .Net Framework WSS will ship as part of the OS; SharePoint Portal Server is built on top of WSS

mhostetler
Download Presentation

Extending SharePoint through Web Parts and ASP.NET

An Image/Link below is provided (as is) to download presentation Download Policy: Content on the Website is provided to you AS IS for your information and personal use and may not be sold / licensed / shared on other websites without getting consent from its author. Content is provided to you AS IS for your information and personal use only. Download presentation by click this link. While downloading, if for some reason you are not able to download a presentation, the publisher may have deleted the file from their server. During download, if you can't get a presentation, the file might be deleted by the publisher.

E N D

Presentation Transcript


  1. Extending SharePoint through Web Parts and ASP.NET 최승현 대리(shchoi@microsoft.com) 한국마이크로소프트

  2. Built on .Net Framework • Windows SharePoint Server (WSS) v2 is built on top of the .Net Framework • WSS will ship as part of the OS; SharePoint Portal Server is built on top of WSS • WSS has made large investments in developer extensibility • By embracing .NET, WSS is positioned to leverage future advances in the platform

  3. Summary of .NET support • WSS will use ASP.NET instead of ISAPI for base page execution • Web Part Framework • Server Object Model for programmatic access to SharePoint data • We offer functionality as XML web services for access from remote machines

  4. Web Custom Controls • Controls map directly to the XML (CAML) tags used on the WSS site pages: • ListViewWebPart A web custom control that will output a SharePoint view • ListFormWebPart A web custom control that will output a SharePoint form. • ViewSelector A web custom control for representing a view selector. • ListProperty A web custom control that returns a property of a list • ProjectProperty A web custom control that returns a given web property

  5. Web Part Framework • Personalize your SharePoint home page to simplify and focus on the information that is most relevant to you. • Authors build custom solutions using Web Parts and Web Part Pages. • .NET developers extend SharePoint by encapsulating web services and enterprise data as Web Parts

  6. Extending the Platform • Web Part Pages • Scalable Dashboards v2 • Framework for extending SharePoint • Web Parts • ASP.NET web custom controls are the building blocks of Web Part Pages • Visual display of SharePoint liWSS, web services, corporate information, etc. • End users, authors, and developers

  7. Using Web Part Pages • Shared View and Personal View allows users to simplify and focus on the most important information. • Find and integrate data from many sources. • Layout and settings are easy to configure. • Catalogs offer new content to add to your page. • Information is available on other browsers.

  8. Portable Web Parts • Web Part is a .Net web custom control assembly • DWP files contain meta-data describing the instance of the part • Code doesn’t travel with the part • Box administrators must install the assembly

  9. DWP Sample

  10. FrontPage • Continues to be a great tool for customizing SharePoint sites • Visual presentations on web services without writing code using the DataView Web Part • Setting zone properties • Editing the Html page layout • Link fix-up of base-class parts

  11. HTML view of List Content Editor Page Viewer DataView XML/XSL Web Parts for Authors • Windows SharePoint Server: • Office: • Web Capture Web Part • Spreadsheet • PivotView • ChartView • Grid View of List

  12. Connecting Parts Together • Parts sending messages to other parts • RCA cables • Standardized client and server interfaces • Web Part interfaces • IList • IRow • ICell • IFilter • Transforms

  13. Key Features for Developers • An extension to the .Net Framework: • Installed when you install WSS v2 • Web Part Pages are ASP.NET pages • Web Parts are ASP.NET web custom controls • Scales out for large server farms • Use Visual Studio to quickly build, test, and deploy custom Web Parts.

  14. Web Part Zones • Stuff on the Page… • Web Part Zones are embedded directly on the page • Stuff in the db… • All users and just for me web parts inside zones are stored in the SharePoint WebParts table • Personalizations are stored in the SharePoint Personalizations table <SmartPages:WebPartZone runat="server" Title=“Left ZoneID=“…" Orientation="Vertical“ AllowCustomization=“true” AllowPersonalization=“true”/>

  15. Web Part Zones ASP.NET Page Web Part Framework ASP.NET Page Zone 1 Zone 3 Zone 2 Content DB Web Custom Controls

  16. Zone Properties • Layout Properties • ID • Orientation • ContainerWidth • Title • FrameType • Lockdown Properties • LockLayout • AllowCustomization • AllowPersonalization

  17. Properties • Base class properties • Custom Properties • Default property sheet for browseable properties with builder infrastructure • Use ToolParts for creating custom property UI • There are limited types because we are serializing properties: • string, bool, int, float, enum, System.DateTime, and System.Drawing.KnownColor

  18. Web Part Properties [Category("Custom Properties")] [WebPartStorage(Storage.PerUser)] [FriendlyNameAttribute("Custom Integer")] [Description("Type an integer value.") ] [Browsable(true)] [XmlElement(ElementName="SuperInt")] public int MyInt { get { return _myInt; } set { _myInt = value; } }

  19. Web Part Caching • Using code developers have the ability to cache rendered output • Two types of web part application caching • ASP.NET web server memory caching • Database caching • Web.config setting for which type

  20. Other Framework Features • Run-time filter enables the ability to turn parts on and off • Developers can add and remove Web Part menu items • Developers can create custom views of the Task Pane using ToolParts

  21. Web Part Code Access Security • Code access security (CAS) allows box administrators grant specific rights to assemblies • Goal of CAS is to separate access rights of the user from the access rights of the assembly • Admin can deny access to local resources for partial trusted assemblies • Admin can allocate trust based on signatures, strong names, and certificates

  22. Rights and Roles • WSS has 4 user roles • Reader—Cannot change web part properties • Contributor • Pages in webs—Can make personal changes • Pages in document libraries—Can make authoring changes along with personal changes • Web Designer—Can make authoring changes for all pages • Administrator—Can upload web parts to the web part catalog

  23. Security • Only registered set of web custom controls will run in SharePoint pages • Inline script in the page will not execute • Code behind in pages can be made to work • All Executable code (e.g. web custom controls, web parts, and code-behind classes) needs to be installed on physical web server

  24. GetSmartPageDocument SaveWebPart DeleteWebPart RenderWebPartForEdit GetWebPart AddWebPart GetWebPartProperties GetXmlDataFromDataSource GetWebPartCrossPageCompatibility GetSmartPageConnectionInfo GetWebPartsForDoc Web Services Object Model • Rich web service support for driving sites. • FrontPage uses these public web services for page authoring. • Path to web services: http://[servername]/_vti_bin/smartpgs.asmx

More Related