71
www.supinfo.com Copyright © SUPINFO. All rights reserved

Www.supinfo.com Copyright © SUPINFO. All rights reserved

Embed Size (px)

Citation preview

Page 1: Www.supinfo.com Copyright © SUPINFO. All rights reserved

www.supinfo.com

Copyright © SUPINFO. All rights reserved

Page 2: Www.supinfo.com Copyright © SUPINFO. All rights reserved

Agenda

Introduction & Installation for developers

SharePoint Designer 2010

VS2010 Tools

List & Event Handler

DashBoard Developer

Visual WebParts

How to use the ribbon

Dialog framework & Status bar

Page 3: Www.supinfo.com Copyright © SUPINFO. All rights reserved

Agenda (suite)

Linq To SharePoint

Client Object Model

Rest Services

SandBoxed Applications

Workflows novelties

Page 4: Www.supinfo.com Copyright © SUPINFO. All rights reserved

Introduction & Installation

Page 5: Www.supinfo.com Copyright © SUPINFO. All rights reserved

5

Become a super Become a super developer with developer with

SharePoint 2010SharePoint 2010

Page 6: Www.supinfo.com Copyright © SUPINFO. All rights reserved

The SharePoint Platform

SharePoint Server CapabilitiesSharePoint Server Capabilities

Pages and User InterfacePages and User Interface

Web UIWeb UI

FrameworkFrameworkSilverlightSilverlight

Server APIsServer APIs

LINQLINQ

Connected Client APIsConnected Client APIs

RESTREST Client OMClient OM

Application LifecycleApplication LifecycleApplication Model (Sites)Application Model (Sites)

External ListsExternal Lists

Data Model ListsData Model Lists Content ManagementContent Management

Page 7: Www.supinfo.com Copyright © SUPINFO. All rights reserved

Installation

Windows Server 2008, 2008 R2, 7

X64 bits (VMWare, Virtualisation, Natif)

VHD Boot (BCDEdit UI codeplex):

http://blogs.dotnet-france.com/juliend/post/SharePoint2010-Creer-une-machine-pour-developpeur.aspx

Page 8: Www.supinfo.com Copyright © SUPINFO. All rights reserved

A new master page and new Technologies

Page 9: Www.supinfo.com Copyright © SUPINFO. All rights reserved

Demo Introduction

Page 10: Www.supinfo.com Copyright © SUPINFO. All rights reserved

SharePoint Designer 2010

Page 11: Www.supinfo.com Copyright © SUPINFO. All rights reserved

SharePoint Designer 2010

Free product, Web expression range New tools

XSLT View List schema …

Improvements Workflow Designer Page Editor

A better integration in Pages

Page 12: Www.supinfo.com Copyright © SUPINFO. All rights reserved

Demo SharePoint Designer

Page 13: Www.supinfo.com Copyright © SUPINFO. All rights reserved

Visual 2010 Tools

Page 14: Www.supinfo.com Copyright © SUPINFO. All rights reserved

14

Visual Studio 2010 SharePoint Tools

Develop/Unfold and debug SP projects

Packaging Explorer

Web Part Designer

Workflow Designer (WF) and Web Part

Package et Unfold your Sharepoint Projects

Generate WSP files for your sites in production

Use Server Explorer

Integrate your development in TFS

Page 15: Www.supinfo.com Copyright © SUPINFO. All rights reserved

With VS2008 for SP2007

Visual Studio experience was limited

Visual Studio Extensions for WSS 1.3 March

Many tools coming from community (and so support problems, globalization…)

It was necessary to manage:

Manually CAML files

Know the arborescence of file “12”

Edit himself manifest.xml files

Generate his .wsp files

Page 16: Www.supinfo.com Copyright © SUPINFO. All rights reserved

With VS2010 for SP2010

Developer experience increased

SharePoint Explorer

No need to have SharePoint on his computer

Basic integrated Tools

Migration tools of your project VS2008/WSS 3.0

Extensible

Benefits:

Abstraction of directory “14”

Abstraction of WSP generation

Less external utilities

Page 17: Www.supinfo.com Copyright © SUPINFO. All rights reserved

SharePoint Explorer

Add-in for “Server Explorer” window

Easy to use

Practical for launching browser on the right page

Page 18: Www.supinfo.com Copyright © SUPINFO. All rights reserved

F5 Key

What does it really do ?

1.Creation of .wsp file2.Feature Disable/Uninstall3.Old .wsp files removal4.Deployment of .wsp file5.Feature activation6.Automatic bond to the

process W3WP.EXE

Page 19: Www.supinfo.com Copyright © SUPINFO. All rights reserved

Demo Visual Studio 2010 Tools

Page 20: Www.supinfo.com Copyright © SUPINFO. All rights reserved

List & Event Handler

Page 21: Www.supinfo.com Copyright © SUPINFO. All rights reserved

Novelties

New events MSF 4.0

WebAdding & WebProvisioned

ListAdding & ListAdded

ListDeleting & ListDeleted

MSF 4.0 can take up to 50 millions of elements in a list

Page 22: Www.supinfo.com Copyright © SUPINFO. All rights reserved

Rational Lists & Joints

MSF 4.0 introduces reinforced relations with a “Lookup” field

Novelties :

Projected fields in “children” lists

Joints

Data’s integrity

Page 23: Www.supinfo.com Copyright © SUPINFO. All rights reserved

Projected fields

Passage of list’s data from a parent one to a child one

The way to achieve this is the same as a “lookup” with WSS 3.0

Page 24: Www.supinfo.com Copyright © SUPINFO. All rights reserved

Joints

Joints are tolerated

Available with API(s), CAML and SharePoint Designer

New properties for SPQuery:

SPQuery.Join

SPQuery.ProjectedFields

Use SPLinq

Page 25: Www.supinfo.com Copyright © SUPINFO. All rights reserved

Demo Sharepoint List

Page 26: Www.supinfo.com Copyright © SUPINFO. All rights reserved

Dashboard Developer

Page 27: Www.supinfo.com Copyright © SUPINFO. All rights reserved

DashBoard Developer

Allows you to know your code’s performances :

How long does it take to execute ?

Which events are raised ?

Page 28: Www.supinfo.com Copyright © SUPINFO. All rights reserved

Demo Dashboard Developer

Page 29: Www.supinfo.com Copyright © SUPINFO. All rights reserved

Visual WebParts

Page 30: Www.supinfo.com Copyright © SUPINFO. All rights reserved

Visual Web Parts

Allows to load an “usercontrol” in a “webpart” in an automatic way

Page 31: Www.supinfo.com Copyright © SUPINFO. All rights reserved

Demo Visual WebParts

Page 32: Www.supinfo.com Copyright © SUPINFO. All rights reserved

How to use the ribbon & the dialog framework

Page 33: Www.supinfo.com Copyright © SUPINFO. All rights reserved

33

The ribbon :

Page 34: Www.supinfo.com Copyright © SUPINFO. All rights reserved

Ribbon's controls

Basic

ButtonSplit buttonComboboxCheckboxToggle ButtonLabelTextboxCombo boxSpinnerTable controlColor picker

But also

“Drop Down” to have a subset

Page 35: Www.supinfo.com Copyright © SUPINFO. All rights reserved

35

Status Bar and Notification bar

Status BarStatus Bar

Notification

Notification

Page 36: Www.supinfo.com Copyright © SUPINFO. All rights reserved

36

The dialog framework

Page 37: Www.supinfo.com Copyright © SUPINFO. All rights reserved

Demo Manipulation Ribbon

Page 38: Www.supinfo.com Copyright © SUPINFO. All rights reserved

Demo Dialog Framework & Status Bar

Page 39: Www.supinfo.com Copyright © SUPINFO. All rights reserved

Client Object Model

Page 40: Www.supinfo.com Copyright © SUPINFO. All rights reserved

The OM Client

Subset of the Server OM

Bases to manipulate SharePoint Foundation: Webs, Lists, ListItems, etc.

An unified API

JavaScript

.net CLR

Silverlight CLR

Page 41: Www.supinfo.com Copyright © SUPINFO. All rights reserved

Tolerated objects

Sites’ collection and Sites

Lists, List Items, Views, et list schema.

Files and directories

Web Parts

Security / Users

Content Types

Sites’ Templates

Page 42: Www.supinfo.com Copyright © SUPINFO. All rights reserved

Linq-to-SharePoint

Customer sideCustomer side(.NET/Silverlight/

JavaScript)

Server sideServer side(WebParts, Event Handlers,

Workflows…)

Access to objects and/or data SharePoint 2010

Server Object Model

Web Services

REST APIsClient Object Model

Page 43: Www.supinfo.com Copyright © SUPINFO. All rights reserved

Server Object Model

SharePoint Service

JavaScript Client

Silverlight Client

.NETClient

Exchanges XML/JSON

Client Object Model of SharePoint 2010

Page 44: Www.supinfo.com Copyright © SUPINFO. All rights reserved

Demo OM Client

Page 45: Www.supinfo.com Copyright © SUPINFO. All rights reserved

JavaScript OM

SP.js 380ko

SP.Core.js 13ko

SP.Runtime.js 68ko

Or

<SharePoint:ScriptLink runat="server"  Name="sp.js"/> 

Page 46: Www.supinfo.com Copyright © SUPINFO. All rights reserved

Linq To Sharepoint

Page 47: Www.supinfo.com Copyright © SUPINFO. All rights reserved

SQL Query

string cs =“Data Source=localhost;…..“;using (SqlConnection c = new

SqlConnection(cs)){ c.Open(); SqlCommand cmd = c.CreateCommand(cs); cmd.CommandType = CommandType.Text; cmd.CommandText = “SELECT * FROM…..”; SqlDataReader r = cmd.ExecuteReader();….

Page 48: Www.supinfo.com Copyright © SUPINFO. All rights reserved

XML Query

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

Page 49: Www.supinfo.com Copyright © SUPINFO. All rights reserved

2007-Style CAML Query

<Where> <Gt> <FieldRef Name='EndDate'/> <Value Type='DateTime'> <Today OffsetDays=\"-1\"/> </Value> </Gt></Where>

Page 50: Www.supinfo.com Copyright © SUPINFO. All rights reserved

What is LINQ?

Language Integrated Query

Simple, Object - oriented

Relational data

Check at compiling

Advantages of IntelliSense

Unified syntax for all kinds of data

Page 51: Www.supinfo.com Copyright © SUPINFO. All rights reserved

Demo Linq

Page 52: Www.supinfo.com Copyright © SUPINFO. All rights reserved

LINQ to SharePoint

No CAML

Strongly typed

Microsoft.SharePoint.Linq.dll

Page 53: Www.supinfo.com Copyright © SUPINFO. All rights reserved

Interlist Relations

Interlist requests

Model generation

Page 54: Www.supinfo.com Copyright © SUPINFO. All rights reserved

Data modification

Pseudo mode “transactional” with method SubmitChanges()

Page 55: Www.supinfo.com Copyright © SUPINFO. All rights reserved

Demo Linq to Sharepoint

Page 56: Www.supinfo.com Copyright © SUPINFO. All rights reserved

REST Services

Page 57: Www.supinfo.com Copyright © SUPINFO. All rights reserved

REST APIs

Use of REST on:

Data lists SharePoint

WCF Data Services

REST Architecture

Atom or JSON Sérialization

As a matter of fact, compatible with:

ASP.NET AJAX

PowerPivot

Java

Silverlight

Flash

Page 58: Www.supinfo.com Copyright © SUPINFO. All rights reserved

ADO.NET Data Services

LINQ to SP doesn’t exist in Silverlight (even though the OM Client exists)

ListData.svc allows a total access in CRUD

Page 59: Www.supinfo.com Copyright © SUPINFO. All rights reserved

Demo Astoria

Page 60: Www.supinfo.com Copyright © SUPINFO. All rights reserved

SandBoxed Applications

Page 61: Www.supinfo.com Copyright © SUPINFO. All rights reserved

61

Take notice of Take notice of non-secured non-secured

featuresfeatures

Page 62: Www.supinfo.com Copyright © SUPINFO. All rights reserved

SandBoxed Applications

The code supports all basic templates:

Web Part

Event Receivers

Workflows

But limited to Microsoft.SharePoint

Page 63: Www.supinfo.com Copyright © SUPINFO. All rights reserved

Restrictions

SPSite

SPWeb

SPList

SPListItem

Limitation of resources (memory, SQL, CPU)

No SPSite construction

No access possibilities to SPSecurity

Page 64: Www.supinfo.com Copyright © SUPINFO. All rights reserved

Workflow Novelties

Page 65: Www.supinfo.com Copyright © SUPINFO. All rights reserved

Workflow

Novelties

Display inside the browser

Workflows “out of the box” are personalizable

Page 66: Www.supinfo.com Copyright © SUPINFO. All rights reserved

Demo Workflows

Page 67: Www.supinfo.com Copyright © SUPINFO. All rights reserved

Silverlight & Sharepoint

Page 68: Www.supinfo.com Copyright © SUPINFO. All rights reserved

Silverlight

Silverlight Web Part

Object Model Client in Silverlight

Silverlight is present almost everywhere

Page 69: Www.supinfo.com Copyright © SUPINFO. All rights reserved

Demo Silverlight

Page 70: Www.supinfo.com Copyright © SUPINFO. All rights reserved

70

Questions / Answers (?)Speech is yours

Page 71: Www.supinfo.com Copyright © SUPINFO. All rights reserved

Thank you