Share Point Development With Vs10

Preview:

DESCRIPTION

 

Citation preview

Visual Studio 2010 SharePoint Tools

OutlineIntroduction to VS2010 SharePoint ToolsSharePoint Tools Project StructureAdding SPIs to a ProjectSharePoint Tools Extensibility

SharePoint 2007 Development

Visual Studio Experience Is LimitedVisual Studio Extensions for WSSVisual Studio Tools for Office with VS2008SharePoint developers reliant on community tools

Developers have to deal with tedious detailsManually editing CAML filesUnderstanding RootFiles directory of WSSManual edits to manifest.xml fileBuilding .wsp file for solution package

Visual Studio 2010 SharePoint Tools

End-to-end SharePoint 2010 developer storySharePoint Explorer for site explorationSharePoint 2010 project and item templatesVisual designers for core scenariosMigration path for Visual Studio 2008 for WSS 3.0Extensible by 3rd party developers

Benefits to SharePoint developersAbstracts away details of RootFiles directoryAbstracts away details of building .wsp fileLessens/eliminates need for external utilities

SharePoint ExplorerAdd-in for Server Explorer window

Easy way to examine site artifactsQuick way to launch browser into site

SharePoint Explorer extensibilityDevelopers can write add-ins to populate nodes and provide contextual menu commands

SharePoint Explorer

demo

OutlineIntroduction to VS2010 SharePoint ToolsSharePoint Tools Project StructureAdding SPIs to a ProjectSharePoint Tools Extensibility

SharePoint 2010 Project Templates

SharePoint Projects have standard properties

Project FileProject FolderActive Deployment ConfigurationInclude Assembly in PackageAssembly Deployment TargetSandboxed SolutionSite URLStartup Item

SharePoint 2010 Project StructureStandard Project Nodes

Properties (standard with all Visual Studio projects)

References (standard with all Visual Studio projects)

Features (added by SharePoint Tools)

Package (added by SharePoint Tools)

SharePoint Project Items(added using SharePoint Tools Project Item Templates)

Feature Node and Feature DesignerFeature node contains one or more features

Feature designer provides design mode and XML text ModeCustomize feature properties in designer and/or property gridUse Context menu of Feature node to add feature event receiverFeature designer allows adding/removing SPIsCustomize feature activation dependencies

Mapped Folders

Mapped Folders used to deploy to RootFilesLayouts folder maps to virtual path /_layoutsImages folder maps to virtual path /_layoutsYou can map other folders inside RootFiles directory

Layouts folder key to creating application pagesBest practice to create solution-specific folder inside Layouts

SPT Deployment OptionsTwo Deployment configuration by default

DefaultNo Activation

The F5 Debugging ExperienceWhat does F5 do?1.Builds new version of .wsp file2.Deactivates/uninstalls feature3.Retracts/deletes old .wsp file4.Adds/deploys new .wsp file5.Activates feature in target site (via Site Url)6.Attaches debugger to W3WP.EXE

worker process (via Site URL)

Hello World with VS 2010 SharePoint Tools

demo

OutlineIntroduction to VS2010 SharePoint ToolsSharePoint Tools Project StructureAdding SPIs to a ProjectSharePoint Tools Extensibility

SharePoint Project Items (SPIs)Projects built with SharePoint Items (SPIs)

SPI is a logical collection of project filesExamples of SPIs are WebParts, List Defs, Workflows, etc

Each SPI has folder with SPI filesCompilation & deployment details abstracted away through SPI file properties

SPI File Properties

Project tracks properties for each SPI FileVisual Studio properties for compilationSharePoint 2010 properties for deployment

SharePoint Project Item Templates

MetroWebParts

demo

OutlineIntroduction to VS2010 SharePoint ToolsSharePoint Tools Project StructureAdding SPIs to a ProjectSharePoint Tools Extensibility

SharePoint 2010 Tools Extensibility

SharePoint 2010 Project system extensibilityCustom extensions integrate into VS10 designer experienceUsed to create custom SPIs not supported out-of-boxMuch easier than standard VS extensibility model

SPI & Context Menu extensibilityExtend VS context menu for standard and custom SPIsProvide extensibility to enable access to SP server API

SP Explorer Nodes & Menu extensibilityCreate extension to add a node to the SP ExplorerCreate extension to enhance existing node

Creating a Custom SPICreating a custom SPI Template

Custom SPI is a creatable project item templateUsed to add SPI instance to SharePoint projectsYou can extend SPI with custom menus and properties

SPI can be extended with custom menu commands

Custom SPI Template used to add SPI instances to project

SPI can be extended with custom properties

Each SPI instance gets it own folder and can be initialized with a set of files

Custom SPI Template

CustomAction

demo

SummaryIntroduction to VS2010 SharePoint ToolsSharePoint Tools Project StructureAdding SPIs to a ProjectSharePoint Tools Extensibility