1 / 45

Entwicklung von SharePoint 2010 Anwendungen

Entwicklung von SharePoint 2010 Anwendungen. Simon Amrein Consultant simon.amrein@trivadis.com Zürich, 23.04.2010. Speaker. Name Simon Amrein Company Trivadis AG Email simon.amrein@trivadis.com. Data are always part of the game. Agenda. Visual Studio 2010 Support LINQ to SharePoint

reid
Download Presentation

Entwicklung von SharePoint 2010 Anwendungen

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. Entwicklung von SharePoint 2010 Anwendungen Simon Amrein Consultant simon.amrein@trivadis.com Zürich, 23.04.2010

  2. Speaker • Name Simon Amrein • Company Trivadis AG • Email simon.amrein@trivadis.com MSDN TechTalk - SharePoint 2010 für Entwickler

  3. Data are always part of the game. Agenda • Visual Studio 2010 Support • LINQ to SharePoint • Client Object Model • Business Connectivity Service MSDN TechTalk - SharePoint 2010 für Entwickler

  4. Visual Studio 2010 • Better support for SharePoint development • Support only for SharePoint 2010 (no extended SharePoint 2007 support) • Easy way to Debug Feature/Solution • F5 – Deployment MSDN TechTalk - SharePoint 2010 für Entwickler

  5. Templates • Event Receivers • Web Partsincl Visual WebPart (no more SmartParts) • Workflows • Content Type • List / Site Definition • BCS Model • Empty Projext MSDN TechTalk - SharePoint 2010 für Entwickler

  6. SharePoint 2010 Project Templates • All Projects built using standard structure • Common Project Properties • Project File • Project Folder • Assembly Deployment Target • Sandboxed Solution • Site URL • Startup Item MSDN TechTalk - SharePoint 2010 für Entwickler

  7. SharePoint 2010 Project Structure • Standard Project Nodes • Properties • References • Features • Package • SharePoint Project Items(optionally added by dev using SharePoint 2010 Developer Tools) MSDN TechTalk - SharePoint 2010 für Entwickler

  8. Server Explorer • Add-in for Server Explorer window • Easy way to examine site artifacts • Quick way to launch browser into site • SharePoint Explorer extensibility • Developers can write add-ins to populate nodes and provide contextual menu commands • Local machines only MSDN TechTalk - SharePoint 2010 für Entwickler

  9. Feature Designer • Configure Feature with VS Support • Define Scope (Farm, Site, Web, WebApplication) MSDN TechTalk - SharePoint 2010 für Entwickler

  10. Package Explorer • Define features and additional files for WSP-Package • Edit Manifest manually if required • The way to build your WSP File – No WSPBuilder needed anymore MSDN TechTalk - SharePoint 2010 für Entwickler

  11. Deployment • F5 deployment on testsystem • STSADM / Powershell • … but Solution Installer is still a good opportunity… MSDN TechTalk - SharePoint 2010 für Entwickler

  12. Data are always part of the game. Demo Visual Studio 2010 MSDN TechTalk - SharePoint 2010 für Entwickler

  13. Data are always part of the game. Agenda • Visual Studio 2010 Support • LINQ to SharePoint • Client Object Model • Business Connectivity Service MSDN TechTalk - SharePoint 2010 für Entwickler

  14. SQL Query string cs =“Data Source=localhost;…..“; using (SqlConnection c = new SqlConnection(cs)) { c.Open(); SqlCommandcmd = c.CreateCommand(cs); cmd.CommandType = CommandType.Text; cmd.CommandText = “SELECT * FROM…..”; SqlDataReader r = cmd.ExecuteReader(); ….

  15. XML Query XmlTextReaderr = new XmlTextReader(“c:\data.xml”); While(r.Read()) { XmlNodeTypent = r.NodeType; switch(nt) { case XmlNodeType.Element: …. case XmlNodeType.Attribute: ….

  16. 2007-Style CAML Query <Where> <Gt> <FieldRef Name='EndDate'/> <Value Type='DateTime'> <Today OffsetDays=\"-1\"/> </Value> </Gt> </Where>

  17. What is LINQ? • Language Integrated Query • Simplified, object-oriented way to query • Bridges OOP and relational data • Compile-time checked queries • Provides IntelliSense inside Visual Studio • Unified syntax for querying any data source MSDN TechTalk - SharePoint 2010 für Entwickler

  18. LINQ to SharePoint • No CAML Required • Entity classes form Business Layer • Strongly-typed queries, compile-time check • Intellisense helps query construction • Microsoft.SharePoint.Linq.dll • Encapsulates the SharePoint object model queries based on the created entity classes MSDN TechTalk - SharePoint 2010 für Entwickler

  19. Using LINQ to SharePoint MSDN TechTalk - SharePoint 2010 für Entwickler

  20. Creating Entity Classes • Generated from spmetal utilityspmetal /web:<site Url> /code:Projects.cs • Create classes and add them to project MSDN TechTalk - SharePoint 2010 für Entwickler

  21. DataContext Object • DataContext class allows access to list data MSDN TechTalk - SharePoint 2010 für Entwickler

  22. Modifying List Data • Changes to entity objects are tracked by Linq provider • Changes submitted SubmitChanges() method is called MSDN TechTalk - SharePoint 2010 für Entwickler

  23. Data are always part of the game. Demo LINQ to SharePoint MSDN TechTalk - SharePoint 2010 für Entwickler

  24. Data are always part of the game. Agenda • Visual Studio 2010 Support • LINQ to SharePoint • Client Object Model • Business Connectivity Service MSDN TechTalk - SharePoint 2010 für Entwickler

  25. Why Client Object Model? • More SharePoint Web services is a major request • Client Object Model provides complete API instead of more services • Provides an abstraction layer to return results as recognizable SharePoint objects • Consistent developer experience across platforms (.NET, ECMAScript, Silverlight) MSDN TechTalk - SharePoint 2010 für Entwickler

  26. Supported Areas • Site Collections and Sites • Lists, List Items, Views, and List Schemas • Files and Folders • Web, List, and List Item Property Bags • Web Parts • Security • Content Types • Site Templates and Site Collection Operations MSDN TechTalk - SharePoint 2010 für Entwickler

  27. Equivalent Objects • Member names mostly the same from server to client (e. g., SPWeb.QuickLaunchEnabled = Web.QuickLaunchEnabled) MSDN TechTalk - SharePoint 2010 für Entwickler

  28. Using the Client Object Model MSDN TechTalk - SharePoint 2010 für Entwickler

  29. .NET Client OM ClientContextclientContext = new ClientContext("http://server"); //Load method clientContext.Load(clientContext.Web); clientContext.Load(clientContext.Web.Lists); //LoadQuery method var q1 = from list          in context.Web.Lists          where list.Title != null          select list; var r1 = context.LoadQuery(q1);

  30. Data are always part of the game. Demo .net Client Object Model MSDN TechTalk - SharePoint 2010 für Entwickler

  31. Silverlight Client OM • Silverlight Development Enabled by Client OM • Can use Silverlight in separate ASPX page or in Web Part • Can utilize Client OM in Silverlight to create SharePoint apps MSDN TechTalk - SharePoint 2010 für Entwickler

  32. Creating Silverlight Web Parts • A Web Part can be a host for Silverlight • SharePoint ships with Silverlight web part • The web part can contain custom properties that are sent to Silverlight via the InitParameters property • The XAP file can be deployed to LAYOUTS and loaded at run time • The Silverlight application can then make use of the Client OM. MSDN TechTalk - SharePoint 2010 für Entwickler

  33. Silverlight Client OM MSDN TechTalk - SharePoint 2010 für Entwickler

  34. Data are always part of the game. Demo Silverlight WebPart MSDN TechTalk - SharePoint 2010 für Entwickler

  35. Data are always part of the game. Agenda • Visual Studio 2010 Support • LINQ to SharePoint • Client Object Model • Business Connectivity Service MSDN TechTalk - SharePoint 2010 für Entwickler

  36. Business Connectivity Services • Provide connectivity support to the following types of external systems: • Databases • Web/WCF services • Microsoft .NET Framework connectivity assemblies • Custom data sources • Read and Write • Provides rich cache, offline work features and supports cache-based operations. • Batch and Bulk Operation Support MSDN TechTalk - SharePoint 2010 für Entwickler

  37. BCS Architecture Office Client SharePoint Server 2010 SharePoint Site External Business Parts VSTO Package External List Custom Code Office Integration Search, Workflow, Web Parts Business Connectivity Services Secure Store Service (SSS) Custom WCF SQL Business Connectivity Services Client Runtime Cache External Content Types (ECT) Server Runtime External Data .NET Connector MSDN TechTalk - SharePoint 2010 für Entwickler

  38. Solution Types, Personas and Tools • Simple SharePoint Designer MSDN TechTalk - SharePoint 2010 für Entwickler

  39. Development Approaches SharePoint Server (Prod / Dev) IT Admin “Live” connection WSP/ ClickOnce Package SI/IT Devs Import & Configure WSP/BDC • No code, discover and configure existing back-end integration end-points • Connect to (existing) WCF, ADO.Net and .Net Objects • Simultaneously author thin and rich client UX for External List and InfoPath Forms Produce WSP/ClickOnce Package w/BDC Model • Create custom back-end integration logic using .Net code • Author thin and rich client UX (independently) as SharePoint and VSTO customization projects SharePoint Designer Pro Dev MSDN TechTalk - SharePoint 2010 für Entwickler

  40. SharePoint Designer • Connecting to an externaldatasource – Just a fewclicks to go… MSDN TechTalk - SharePoint 2010 für Entwickler

  41. Data are always part of the game. Agenda External List – SharePoint Designer MSDN TechTalk - SharePoint 2010 für Entwickler

  42. Visual Studio 2010 Support • The tool for creating “.NET Connectors” MSDN TechTalk - SharePoint 2010 für Entwickler

  43. Data are always part of the game. Agenda External List – Visual Studio MSDN TechTalk - SharePoint 2010 für Entwickler

  44. Courses / Events • Microsoft Ignite Training SharePoint 2010 for developers (4Tg) • 21.06.-24.06.2010 in Zürich • 06.09.-09.09.2010 in Basel • SharePoint 2010 – Was ist neu für Administratoren und IT Professionals (5Tg) • 20.09.-24.09.10 in München • 18.10.-22.10.10 in Zürich MSDN TechTalk - SharePoint 2010 für Entwickler

  45. Thank you! ? www.trivadis.com

More Related