Download presentation
Presentation is loading. Please wait.
Published byPiers Morgan Modified over 8 years ago
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 ListViewWebPart ListFormWebPart A web custom control that will output a SharePoint form. ListFormWebPart ViewSelector A web custom control for representing a view selector. ViewSelector ListProperty A web custom control that returns a property of a list ListProperty ProjectProperty A web custom control that returns a given web property ProjectProperty
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
Web Parts for Authors HTML view of List Content Editor Page Viewer DataView XML/XSL Web Capture Web Part Spreadsheet PivotView ChartView Grid View of List Office: Windows SharePoint Server:
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 Zone 2 Zone 1 Zone 3 Web Part Framework Content DB ASP.NET Page 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
Web Services Object Model GetSmartPageDocument SaveWebPart DeleteWebPart RenderWebPartForEdit GetWebPart AddWebPart GetWebPartProperties GetXmlDataFromDataSource GetWebPartCrossPageCompatibility GetSmartPageConnectionInfo GetWebPartsForDoc 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
Similar presentations
© 2024 SlidePlayer.com. Inc.
All rights reserved.