SlideShare a Scribd company logo
1 of 31
Managing (O365) with PowerShell + CSOM
GOLDRAFFLESILVER
PLATINUM
HELLO!My name is
Amit VasuSr. SharePoint Consultant, MVP
www.amitvasu.com
Twitter: @amitvasu
Session Objective
 Understand how to automate different SharePoint
Online (Office 365) tasks using PowerShell and CSOM
 This session is for Developers
 And IT Pro as well
……May be NOT 
History Lesson
Amit’s PowerShell + CSOM Journey
“FTC to CAM – Stop creating content types and site
columns declaratively”
http://blogs.msdn.com/b/vesku/archive/2013/11/06/ftc-to-cam-stop-creating-content-types-and-site-
columns-declaratively.aspx
Typical CT deployment process
How do we overcome - On Premises
What are the challenges with O365
 Guidance to not use declarative code for CT
 You cannot use custom code in Sandbox solution.
 Farm solutions are out of question.
Remote Provisioning to Rescue
Remote Provisioning
 Write C# CSOM/REST Provider hosted App
 JSOM
 PowerShell + CSOM
SharePoint Farm
1
Provider Hosted
Apps
Own app specific
configuration
Artefacts
2
4
CSOM / REST
3
Remote Provisioning Process – CSOM/REST
CSOM – Power Talk
Remote Provisioning
 Client side library for remotely communicating with SharePoint
 Introduced in SharePoint 2010
 Expanded upon in SharePoint 2013
CSOM in SharePoint 2010
CSOM in SharePoint 2013
How CSOM Works
CSOM – Code Example
 Create Context
ClientContext ctx = new ClientContext("http://intranet.contoso.com");
 Call Load and ExecuteQuery Before Accessing Value Properties
Web web = ctx.Web;
ctx.Load(web);
ctx.ExecuteQuery();
Console.WriteLine(web.Title);
How do I start
Steps to start developing
 Pick your Development environment
 Local Machine
 SharePoint 2013 Environment
Local Machine
 Required copy of all SharePoint Client DLL
 Located at C:Program FilesCommon Filesmicrosoft sharedWeb Server
Extensions15ISAPI
 All DLLs that starts with Microsoft.SharePoint.Client
 Reference them in your code from the location you copied them
SharePoint Environment
 No need to do anything other than referencing DLLs
from ISAPI folder.
Optional – Download CSOM Assemblies
DEMO
PowerShell + CSOM
Summary
Why PowerShell + CSOM
 Anything you can do with CSOM can be achieved using PowerShell
+ CSOM
 Great way to extend PowerShell capabilities
 Can be used with SharePoint Online and On-premises
 Spend time understanding CSOM
 Microsoft.SharePoint.Client namespace
Resources
 https://sharepointpowershell.codeplex.com/
 https://sharepointonlineautomationcmdlets.codeplex.com/
 http://social.technet.microsoft.com/wiki/contents/articles/29518.c
som-sharepoint-powershell-reference-and-example-codes.aspx
GOLDRAFFLESILVER
PLATINUM
Thank you!
Toronto Enterprise Collaboration User Group
Change Management, Governance, SharePoint, Office 365,
Yammer, PowerBI, etc
http://www.meetup.com/TSPBUG/
Toronto SharePoint Business Users Group
http://www.meetup.com/TorontoSPUG/
Saturday July 9, 2016
See you next year!
EVALS
http://spbuzz.it/spsto2015-evals
THANK YOU

More Related Content

What's hot

20140211 BTUG.be - Workflow Manager
20140211 BTUG.be - Workflow Manager20140211 BTUG.be - Workflow Manager
20140211 BTUG.be - Workflow Manager
BTUGbe
 

What's hot (20)

Spsct15 power shell_csom - amit vasu
Spsct15 power shell_csom - amit vasuSpsct15 power shell_csom - amit vasu
Spsct15 power shell_csom - amit vasu
 
Typescript 102 angular and type script
Typescript 102   angular and type scriptTypescript 102   angular and type script
Typescript 102 angular and type script
 
TypeScript and SharePoint Framework
TypeScript and SharePoint FrameworkTypeScript and SharePoint Framework
TypeScript and SharePoint Framework
 
Azure Web Jobs
Azure Web JobsAzure Web Jobs
Azure Web Jobs
 
Visual studio 2017 - Launch Event Keynote
Visual studio 2017  - Launch Event KeynoteVisual studio 2017  - Launch Event Keynote
Visual studio 2017 - Launch Event Keynote
 
Cross-Platform Mobile Development using Visual Studio and Xamarin
Cross-Platform Mobile Development using Visual Studio and XamarinCross-Platform Mobile Development using Visual Studio and Xamarin
Cross-Platform Mobile Development using Visual Studio and Xamarin
 
.NET Conf 2019 高雄場 - .NET Core 3.0
.NET Conf 2019 高雄場 - .NET Core 3.0.NET Conf 2019 高雄場 - .NET Core 3.0
.NET Conf 2019 高雄場 - .NET Core 3.0
 
TechNet Conference 2013 Berlin-Wie Sie Office 365 mit Windows Azure steuern b...
TechNet Conference 2013 Berlin-Wie Sie Office 365 mit Windows Azure steuern b...TechNet Conference 2013 Berlin-Wie Sie Office 365 mit Windows Azure steuern b...
TechNet Conference 2013 Berlin-Wie Sie Office 365 mit Windows Azure steuern b...
 
20140211 BTUG.be - Workflow Manager
20140211 BTUG.be - Workflow Manager20140211 BTUG.be - Workflow Manager
20140211 BTUG.be - Workflow Manager
 
SharePoint Framework -The future of SharePoint/ Office 365 developer ecosystem.
SharePoint Framework -The future of SharePoint/ Office 365 developer ecosystem. SharePoint Framework -The future of SharePoint/ Office 365 developer ecosystem.
SharePoint Framework -The future of SharePoint/ Office 365 developer ecosystem.
 
Community Tour Bologna
Community Tour BolognaCommunity Tour Bologna
Community Tour Bologna
 
Office 365 Directory Synchronization
Office 365 Directory SynchronizationOffice 365 Directory Synchronization
Office 365 Directory Synchronization
 
Build 2017 - B8110 - Modernize WinForms and WPF apps with maximum code reuse,...
Build 2017 - B8110 - Modernize WinForms and WPF apps with maximum code reuse,...Build 2017 - B8110 - Modernize WinForms and WPF apps with maximum code reuse,...
Build 2017 - B8110 - Modernize WinForms and WPF apps with maximum code reuse,...
 
Build 2017 - B8083 - The future of Visual Studio
Build 2017 - B8083 - The future of Visual StudioBuild 2017 - B8083 - The future of Visual Studio
Build 2017 - B8083 - The future of Visual Studio
 
Chris OBrien - Pitfalls when developing with the SharePoint Framework (SPFx)
Chris OBrien - Pitfalls when developing with the SharePoint Framework (SPFx)Chris OBrien - Pitfalls when developing with the SharePoint Framework (SPFx)
Chris OBrien - Pitfalls when developing with the SharePoint Framework (SPFx)
 
Building Next Generation Web Apps and Services using ASP.NET 5
Building Next Generation Web Apps and Services using ASP.NET 5Building Next Generation Web Apps and Services using ASP.NET 5
Building Next Generation Web Apps and Services using ASP.NET 5
 
Azure Mobile Services for Cross Platform Mobile Apps
Azure Mobile Services for Cross Platform Mobile AppsAzure Mobile Services for Cross Platform Mobile Apps
Azure Mobile Services for Cross Platform Mobile Apps
 
How to Win #BestMicrosoftHack with Azure
How to Win #BestMicrosoftHack with AzureHow to Win #BestMicrosoftHack with Azure
How to Win #BestMicrosoftHack with Azure
 
SP2010 Developer Tools
SP2010 Developer ToolsSP2010 Developer Tools
SP2010 Developer Tools
 
ASP.NET 5 Overview for Apex Systems
ASP.NET 5 Overview for Apex SystemsASP.NET 5 Overview for Apex Systems
ASP.NET 5 Overview for Apex Systems
 

Viewers also liked

Happy Birthday Mama Joan
Happy Birthday Mama JoanHappy Birthday Mama Joan
Happy Birthday Mama Joan
hafted
 
Lyric analysis what artist is saying
Lyric analysis what artist is sayingLyric analysis what artist is saying
Lyric analysis what artist is saying
haverstockmedia
 
John J. Brown Resume 5.5.10
John J. Brown Resume 5.5.10John J. Brown Resume 5.5.10
John J. Brown Resume 5.5.10
John Brown
 
Additive Manufacturing in Space
Additive Manufacturing in SpaceAdditive Manufacturing in Space
Additive Manufacturing in Space
Arvind Srinivasan
 
Universidad tecnica luis vargas torres de esmeraldas
Universidad tecnica luis vargas torres  de esmeraldasUniversidad tecnica luis vargas torres  de esmeraldas
Universidad tecnica luis vargas torres de esmeraldas
rodriguezelena
 
cultura e religião do norte
cultura e religião do nortecultura e religião do norte
cultura e religião do norte
MAIANASC
 

Viewers also liked (12)

Happy Birthday Mama Joan
Happy Birthday Mama JoanHappy Birthday Mama Joan
Happy Birthday Mama Joan
 
Lyric analysis what artist is saying
Lyric analysis what artist is sayingLyric analysis what artist is saying
Lyric analysis what artist is saying
 
John J. Brown Resume 5.5.10
John J. Brown Resume 5.5.10John J. Brown Resume 5.5.10
John J. Brown Resume 5.5.10
 
Sn 531 80
Sn 531 80Sn 531 80
Sn 531 80
 
Diapositivas angelica
Diapositivas angelicaDiapositivas angelica
Diapositivas angelica
 
Additive Manufacturing in Space
Additive Manufacturing in SpaceAdditive Manufacturing in Space
Additive Manufacturing in Space
 
Universidad tecnica luis vargas torres de esmeraldas
Universidad tecnica luis vargas torres  de esmeraldasUniversidad tecnica luis vargas torres  de esmeraldas
Universidad tecnica luis vargas torres de esmeraldas
 
Teoria społecznego-uczenia-się
Teoria społecznego-uczenia-sięTeoria społecznego-uczenia-się
Teoria społecznego-uczenia-się
 
Update on Risperdal Mass Tort Litigation with Robert Mosier
Update on Risperdal Mass Tort Litigation with Robert MosierUpdate on Risperdal Mass Tort Litigation with Robert Mosier
Update on Risperdal Mass Tort Litigation with Robert Mosier
 
Private hospitals’ parking health care’s debated contribution in traffic cong...
Private hospitals’ parking health care’s debated contribution in traffic cong...Private hospitals’ parking health care’s debated contribution in traffic cong...
Private hospitals’ parking health care’s debated contribution in traffic cong...
 
cultura e religião do norte
cultura e religião do nortecultura e religião do norte
cultura e religião do norte
 
Aula 1 Participação política e cidadania - 3º Sociologia - Prof. Noe Assunção
Aula 1   Participação política e cidadania - 3º Sociologia - Prof. Noe AssunçãoAula 1   Participação política e cidadania - 3º Sociologia - Prof. Noe Assunção
Aula 1 Participação política e cidadania - 3º Sociologia - Prof. Noe Assunção
 

Similar to SPSToronto 2015 - Managing Office365 with PowerShell and CSOM

MS Day EPITA 2010: Visual Studio 2010 et Framework .NET 4.0
MS Day EPITA 2010: Visual Studio 2010 et Framework .NET 4.0MS Day EPITA 2010: Visual Studio 2010 et Framework .NET 4.0
MS Day EPITA 2010: Visual Studio 2010 et Framework .NET 4.0
Thomas Conté
 
Sys02 best way to create a share point app
Sys02   best way to create a share point appSys02   best way to create a share point app
Sys02 best way to create a share point app
DotNetCampus
 

Similar to SPSToronto 2015 - Managing Office365 with PowerShell and CSOM (20)

Chris O'Brien - Modern SharePoint development: techniques for moving code off...
Chris O'Brien - Modern SharePoint development: techniques for moving code off...Chris O'Brien - Modern SharePoint development: techniques for moving code off...
Chris O'Brien - Modern SharePoint development: techniques for moving code off...
 
Rock the ActivityStream API
Rock the ActivityStream APIRock the ActivityStream API
Rock the ActivityStream API
 
Integrate connections and twitter
Integrate connections and twitterIntegrate connections and twitter
Integrate connections and twitter
 
PowerShell Scripting and AI-infused Automation
PowerShell Scripting and AI-infused AutomationPowerShell Scripting and AI-infused Automation
PowerShell Scripting and AI-infused Automation
 
MS Day EPITA 2010: Visual Studio 2010 et Framework .NET 4.0
MS Day EPITA 2010: Visual Studio 2010 et Framework .NET 4.0MS Day EPITA 2010: Visual Studio 2010 et Framework .NET 4.0
MS Day EPITA 2010: Visual Studio 2010 et Framework .NET 4.0
 
DODN2009 - Jump Start Silverlight
DODN2009 - Jump Start SilverlightDODN2009 - Jump Start Silverlight
DODN2009 - Jump Start Silverlight
 
Introducción al SharePoint Framework SPFx
Introducción al SharePoint Framework SPFxIntroducción al SharePoint Framework SPFx
Introducción al SharePoint Framework SPFx
 
Spsnyc 2014 o365 power shell csom
Spsnyc 2014   o365 power shell csomSpsnyc 2014   o365 power shell csom
Spsnyc 2014 o365 power shell csom
 
SharePoint for the .NET Developer
SharePoint for the .NET DeveloperSharePoint for the .NET Developer
SharePoint for the .NET Developer
 
Sps Boston The Share Point Beast
Sps Boston   The Share Point BeastSps Boston   The Share Point Beast
Sps Boston The Share Point Beast
 
Microsoft Team Foundation Server Build 2015
Microsoft Team Foundation Server Build 2015Microsoft Team Foundation Server Build 2015
Microsoft Team Foundation Server Build 2015
 
2014 SharePoint Saturday Melbourne Apps or not to Apps
2014 SharePoint Saturday Melbourne Apps or not to Apps2014 SharePoint Saturday Melbourne Apps or not to Apps
2014 SharePoint Saturday Melbourne Apps or not to Apps
 
2008 - TechDays PT: Building Software + Services with Volta
2008 - TechDays PT: Building Software + Services with Volta2008 - TechDays PT: Building Software + Services with Volta
2008 - TechDays PT: Building Software + Services with Volta
 
Intro to SharePoint for Developers
Intro to SharePoint for DevelopersIntro to SharePoint for Developers
Intro to SharePoint for Developers
 
SharePoint Mobile App Development with Xmarin
SharePoint Mobile App Development with XmarinSharePoint Mobile App Development with Xmarin
SharePoint Mobile App Development with Xmarin
 
Intro to PowerShell
Intro to PowerShellIntro to PowerShell
Intro to PowerShell
 
php
phpphp
php
 
MongoDB.local Dallas 2019: MongoDB Stitch Tutorial
MongoDB.local Dallas 2019: MongoDB Stitch TutorialMongoDB.local Dallas 2019: MongoDB Stitch Tutorial
MongoDB.local Dallas 2019: MongoDB Stitch Tutorial
 
Sys02 best way to create a share point app
Sys02   best way to create a share point appSys02   best way to create a share point app
Sys02 best way to create a share point app
 
Power Shell As A Tools Platform
Power Shell As A Tools PlatformPower Shell As A Tools Platform
Power Shell As A Tools Platform
 

More from amitvasu

Using workflows in share point 2010
Using workflows in share point 2010Using workflows in share point 2010
Using workflows in share point 2010
amitvasu
 

More from amitvasu (12)

Introducing-Loop.pdf
Introducing-Loop.pdfIntroducing-Loop.pdf
Introducing-Loop.pdf
 
Updating your classic team site to use new office 365 features amit vasu
Updating your classic team site to use new office 365 features   amit vasuUpdating your classic team site to use new office 365 features   amit vasu
Updating your classic team site to use new office 365 features amit vasu
 
Introduction to azure functions
Introduction to azure functionsIntroduction to azure functions
Introduction to azure functions
 
Office 365 directory synchronization - SPSDC Reston
Office 365 directory synchronization - SPSDC RestonOffice 365 directory synchronization - SPSDC Reston
Office 365 directory synchronization - SPSDC Reston
 
Tspug 2015 dirsync_amit_v_momentum
Tspug 2015 dirsync_amit_v_momentumTspug 2015 dirsync_amit_v_momentum
Tspug 2015 dirsync_amit_v_momentum
 
Spsdc what's new in share point 2013 workflow
Spsdc   what's new in share point 2013 workflowSpsdc   what's new in share point 2013 workflow
Spsdc what's new in share point 2013 workflow
 
Sps boston 2014_o365_power_shell_csom_amitv
Sps boston 2014_o365_power_shell_csom_amitvSps boston 2014_o365_power_shell_csom_amitv
Sps boston 2014_o365_power_shell_csom_amitv
 
Sps albany 2014_workflows_amit_vasu
Sps albany 2014_workflows_amit_vasuSps albany 2014_workflows_amit_vasu
Sps albany 2014_workflows_amit_vasu
 
Spsdc using sp2013 to crawl sp2010 farm
Spsdc using sp2013 to crawl sp2010 farmSpsdc using sp2013 to crawl sp2010 farm
Spsdc using sp2013 to crawl sp2010 farm
 
Sps ottawa 2013_workflows_amit_vasu
Sps ottawa 2013_workflows_amit_vasuSps ottawa 2013_workflows_amit_vasu
Sps ottawa 2013_workflows_amit_vasu
 
Spsto 2013 whats_newinworkflows_amitvasu.
Spsto 2013 whats_newinworkflows_amitvasu.Spsto 2013 whats_newinworkflows_amitvasu.
Spsto 2013 whats_newinworkflows_amitvasu.
 
Using workflows in share point 2010
Using workflows in share point 2010Using workflows in share point 2010
Using workflows in share point 2010
 

Recently uploaded

Architecting Cloud Native Applications
Architecting Cloud Native ApplicationsArchitecting Cloud Native Applications
Architecting Cloud Native Applications
WSO2
 
Finding Java's Hidden Performance Traps @ DevoxxUK 2024
Finding Java's Hidden Performance Traps @ DevoxxUK 2024Finding Java's Hidden Performance Traps @ DevoxxUK 2024
Finding Java's Hidden Performance Traps @ DevoxxUK 2024
Victor Rentea
 
Cloud Frontiers: A Deep Dive into Serverless Spatial Data and FME
Cloud Frontiers:  A Deep Dive into Serverless Spatial Data and FMECloud Frontiers:  A Deep Dive into Serverless Spatial Data and FME
Cloud Frontiers: A Deep Dive into Serverless Spatial Data and FME
Safe Software
 

Recently uploaded (20)

Apidays New York 2024 - Passkeys: Developing APIs to enable passwordless auth...
Apidays New York 2024 - Passkeys: Developing APIs to enable passwordless auth...Apidays New York 2024 - Passkeys: Developing APIs to enable passwordless auth...
Apidays New York 2024 - Passkeys: Developing APIs to enable passwordless auth...
 
Introduction to Multilingual Retrieval Augmented Generation (RAG)
Introduction to Multilingual Retrieval Augmented Generation (RAG)Introduction to Multilingual Retrieval Augmented Generation (RAG)
Introduction to Multilingual Retrieval Augmented Generation (RAG)
 
[BuildWithAI] Introduction to Gemini.pdf
[BuildWithAI] Introduction to Gemini.pdf[BuildWithAI] Introduction to Gemini.pdf
[BuildWithAI] Introduction to Gemini.pdf
 
MS Copilot expands with MS Graph connectors
MS Copilot expands with MS Graph connectorsMS Copilot expands with MS Graph connectors
MS Copilot expands with MS Graph connectors
 
Polkadot JAM Slides - Token2049 - By Dr. Gavin Wood
Polkadot JAM Slides - Token2049 - By Dr. Gavin WoodPolkadot JAM Slides - Token2049 - By Dr. Gavin Wood
Polkadot JAM Slides - Token2049 - By Dr. Gavin Wood
 
Repurposing LNG terminals for Hydrogen Ammonia: Feasibility and Cost Saving
Repurposing LNG terminals for Hydrogen Ammonia: Feasibility and Cost SavingRepurposing LNG terminals for Hydrogen Ammonia: Feasibility and Cost Saving
Repurposing LNG terminals for Hydrogen Ammonia: Feasibility and Cost Saving
 
DEV meet-up UiPath Document Understanding May 7 2024 Amsterdam
DEV meet-up UiPath Document Understanding May 7 2024 AmsterdamDEV meet-up UiPath Document Understanding May 7 2024 Amsterdam
DEV meet-up UiPath Document Understanding May 7 2024 Amsterdam
 
presentation ICT roal in 21st century education
presentation ICT roal in 21st century educationpresentation ICT roal in 21st century education
presentation ICT roal in 21st century education
 
Exploring Multimodal Embeddings with Milvus
Exploring Multimodal Embeddings with MilvusExploring Multimodal Embeddings with Milvus
Exploring Multimodal Embeddings with Milvus
 
Navigating the Deluge_ Dubai Floods and the Resilience of Dubai International...
Navigating the Deluge_ Dubai Floods and the Resilience of Dubai International...Navigating the Deluge_ Dubai Floods and the Resilience of Dubai International...
Navigating the Deluge_ Dubai Floods and the Resilience of Dubai International...
 
Architecting Cloud Native Applications
Architecting Cloud Native ApplicationsArchitecting Cloud Native Applications
Architecting Cloud Native Applications
 
Corporate and higher education May webinar.pptx
Corporate and higher education May webinar.pptxCorporate and higher education May webinar.pptx
Corporate and higher education May webinar.pptx
 
Finding Java's Hidden Performance Traps @ DevoxxUK 2024
Finding Java's Hidden Performance Traps @ DevoxxUK 2024Finding Java's Hidden Performance Traps @ DevoxxUK 2024
Finding Java's Hidden Performance Traps @ DevoxxUK 2024
 
Cloud Frontiers: A Deep Dive into Serverless Spatial Data and FME
Cloud Frontiers:  A Deep Dive into Serverless Spatial Data and FMECloud Frontiers:  A Deep Dive into Serverless Spatial Data and FME
Cloud Frontiers: A Deep Dive into Serverless Spatial Data and FME
 
CNIC Information System with Pakdata Cf In Pakistan
CNIC Information System with Pakdata Cf In PakistanCNIC Information System with Pakdata Cf In Pakistan
CNIC Information System with Pakdata Cf In Pakistan
 
Boost Fertility New Invention Ups Success Rates.pdf
Boost Fertility New Invention Ups Success Rates.pdfBoost Fertility New Invention Ups Success Rates.pdf
Boost Fertility New Invention Ups Success Rates.pdf
 
Web Form Automation for Bonterra Impact Management (fka Social Solutions Apri...
Web Form Automation for Bonterra Impact Management (fka Social Solutions Apri...Web Form Automation for Bonterra Impact Management (fka Social Solutions Apri...
Web Form Automation for Bonterra Impact Management (fka Social Solutions Apri...
 
Rising Above_ Dubai Floods and the Fortitude of Dubai International Airport.pdf
Rising Above_ Dubai Floods and the Fortitude of Dubai International Airport.pdfRising Above_ Dubai Floods and the Fortitude of Dubai International Airport.pdf
Rising Above_ Dubai Floods and the Fortitude of Dubai International Airport.pdf
 
Apidays New York 2024 - The value of a flexible API Management solution for O...
Apidays New York 2024 - The value of a flexible API Management solution for O...Apidays New York 2024 - The value of a flexible API Management solution for O...
Apidays New York 2024 - The value of a flexible API Management solution for O...
 
Apidays New York 2024 - Accelerating FinTech Innovation by Vasa Krishnan, Fin...
Apidays New York 2024 - Accelerating FinTech Innovation by Vasa Krishnan, Fin...Apidays New York 2024 - Accelerating FinTech Innovation by Vasa Krishnan, Fin...
Apidays New York 2024 - Accelerating FinTech Innovation by Vasa Krishnan, Fin...
 

SPSToronto 2015 - Managing Office365 with PowerShell and CSOM