SharePoint 2010 for NET Developers

Post on 08-May-2015

4,076 views 0 download

description

slides from my talks in August 2010

transcript

SharePoint Developmentwith Microsoft Visual Studio 2010

Lynn LangitMicrosoft Developer Evangelisthttp://blogs.msdn.com/SoCalDevGal

What & Why SharePoint 2010? .Net / ASP.Net & VS 2010 integration

Huge Install Base

Built-in features

Multiple Editions, including FREE

edition

Communities

Search

Sites

Composites

ContentInsights

Developer Tools

Visual Studio 2010 Windows 7 ALMSharePoint

Designer 2010

Developer Tools · Developer Workstation · Team · Design Tools

Project TemplatesWSP PackagingVisual Designers

One Development MachineFor Developers OnlyX64 OS Required

Source code controlTeam Foundation Server (TFS)

Artifact FocusNew Workflow DesignerExport as WSP

New – Visual Studio – Light Switch (lightweight development) - CTP

SPS 2010 Developer Enhancements

− VS 2010 Enhancements − Templates , Visualizers and more

− New (client) object model− LINQ for SharePoint− Native support for Silverlight− Sandboxed Solutions− Support for claims-based security− Native support for PowerShell

− External data lists− Designed to work with BCS− In all editions of SharePoint

SharePoint Designer – Why?

SPS and PowerShell

An alternative to stsadm.exe

SharePoint Admin Site

BEFORE Developing on VS 2010Understand what you can do via other methods FIRST:• From within a SharePoint site• From within the SharePoint Administrative site• From within SharePoint designer• From Powershell (scripts)• From CodePlex• From public templates

Visual Studio 2010Developer Tools for SharePoint

Server Explorer

Package and Feature Designers

BCS Designer

Workflow Designer

Visual Web Part Designer

**Must run VS2010 ‘as admin’

Leverage .NET and ASP.NET skills− You are using the same tools

− Same designers, controls, etc.− Event handling model− Save “F5” deploy/debug experience

− Familiar programming model− Built on ASP.NET− Built on Windows Workflow Foundation

− Styling is the same− Use JavaScript and Silverlight

SPS Projects in VS 2010

SPS Templates - Then SPS Templates - Now

Deployment: Project Creation

VS 2010 SPS Empty Project

SharePoint Terminology Review- Farm (SPFarm)

- Web Application (SPWebApplication)

- Site Collection (SPSite)

- Site (SPWeb)

- List (SPList) - Item (SPListItem)

- Document Library (SPDocumentLibrary)

- File (SPFile)

- Folder (SPFolder)

VS 2010 SPS Server Explorer

Visual Web Part

− New for SharePoint 2010− Uses ASP.NET User Controls (ASCX)

− Can combine ASP.NET and SharePoint controls− Integrated designer support in Visual

Studio− Develop, deploy, debug using new

SharePoint project system

Demo 1: Visual Web Part

Visual Web Part

Web Part

Packages

Properties: SharePoint Tab

DeploymentF5

You can now DEBUG as well

SharePoint Item Templates

Business Connectivity Services

Business Connectivity Services− Visual designers in VS 2010

− BCS Explorer− BDC method details

− Tool to generate classes− SPMetal - here

Workflow for SPS

− SharePoint 2010 offers new development process− Envision workflows in Visio− Import into SharePoint Designer

− Parameterize− Export to Visual Studio 2010

− Add code

Visio SPD VS10

Creating Workflows in Visio

− Visio has SharePoint Workflow template− Allows you to create workflow design in

Visio− Workflow can be exported to SharePoint

Designer

SharePoint Designer Workflows− Workflows target a Site or a List

Workflows in Visual Studio 2010− Site Workflows

− List / Item properties are null− No auto-start

− ASP.NET Form Templates− New events− External Data Exchange

public class MyWorkflowEventReceiver : SPWorkflowEventReceiver{ public override void WorkflowStarting( SPWorkflowEventProperties properties) { // your code here base.WorkflowStarting(properties); }}

SharePoint 2010 & Silverlight

− New client API build especially for Silverlight

− New Silverlight Web Part to ease deployment and use of Silverlight Applications

− Silverlight supports multi-touch applications

Enabling Rich Visualizations

Consistent Experience

No Touch

<html/>

LowTouch

SharePoint

Artifact

High Touch

SharePoint

Artifact

OM, Web 2.0,Service, …

Demo 2: SharePoint and

Silverlight

Connect people to data

Go where your users are

Leverage your skillset

Enable rich visualizations

Resources

− Learn SharePoint 2010 on Channel 9http://channel9.msdn.com/learn/courses/SharePoint2010Developer/

− SharePoint 2010 Developer Centerhttp://msdn.microsoft.com/SharePoint