SlideShare a Scribd company logo
1 of 26
Managing SharePoint Anywhere 
with Windows PowerHell 
Ryan Dennis
Join us for SharePint 
Location: Sharonville Convention Center 
Follow the SIGNS if you dare 
Sponsored by Accusoft & Focal Point Solutions
Sponsor 
s 
Platinum: 
Gold: 
Bronze:
Let’s Get Social ! 
Twitter: @spscincinnati 
#spspookinnati 
Mobile: www.spsmobile.com 
Check us out on Facebook: 
https://www.facebook.com/spscincy
Submit your feedback! 
He was awesome! 
me@somewhere.com
Ryan Dennis 
Senior SharePoint Consultant at Blue Chip Consulting Group 
Recently published first book as a co-author 
www.bluechip-llc.com 
ryan.dennis@bluechip-llc.com 
@SharePointRyan 
/in/SharePointRyan 
/SharePointRyanDotCom 
www.sharepointryan.com 
SP Geek Father 
Drummer 
Husband 
Scripter Author
Get-Agenda 
• Housekeeping 
• Intro to Advanced Functions 
• SharePoint PowerShell On-Premise 
• SharePoint PowerShell in Office 365 
• Using Client Side Object Model (CSOM) 
code in PowerShell 
• Q&A
Get-Help –Topic “PowerShell” 
…is a task-based command-line shell and 
scripting language designed especially for 
Windows system administration 
…has a task-based scripting language 
…includes powerful object manipulation 
capabilities 
…is built on the .NET Framework
Verb-Noun 
PowerShell uses a Verb-Noun syntax for its 
Cmdlets 
• Get-Something 
• Set-Something 
• New-Something 
• Remove-Something 
Quick Tip! 
Use Get-Verb to find 
approved verbs! Use 
Verb-Noun in your code!
Get-Command & Get-Help 
• Use Get-Command to see available 
commands 
Get-Command –Module 
Microsoft.SharePoint.PowerShell 
Get-Command –Module 
Microsoft.Online.SharePoint.PowerShell 
• Use Get-Help <CmdletName> to get 
help information for a cmdlet 
Quick Tip! 
Add Help to your 
scripts and functions!
Get-Command –Type “SharePoint” 
• SharePoint 2010 
– 500+ Cmdlets… 
– MUCH better than STSADM.exe in prior versions… 
– Can automate complete installations and 
configurations… 
• SharePoint 2013 
– 700+ Cmdlets! 
• Still doesn’t answer every scenario, leaving 
gaps in functionality… 
– Example: Get, New and Remove SharePoint Groups – no cmdlet, easy to write a 
custom function though… 
Opportunity! 
Write our own scripts 
and functions!
Get-Help About_Functions_Advanced 
…allow you to perform operations that are 
similar to the operations you can perform 
with cmdlets 
…quickly write a function without having to 
write a compiled cmdlet using a Microsoft 
.NET Framework language (C#) 
…use the CmdletBinding() attribute to 
identify them as functions that act similar to 
cmdlets Quick Tip! 
Use Get-Help 
About_Functions_Advanced 
for more info!
New-Function –Name “Our First Function” 
• Leverages all of the Write-* cmdlets in the 
Microsoft.PowerShell.Utility module 
• Includes Switch statement, ValidateSet, 
Try/Catch/Finally, etc. 
• Includes comment-based-help with 
examples 
• Can be run just like a cmdlet 
Disclaimer! 
This is NOT a SharePoint 
demo, just a general 
PowerShell demo!
D E M O 
Write-Message
Get-Recap 
• Reviewed Write-Message function… 
• Created output using all Write* types 
• Saw the behavior of –Verbose and –Debug 
switches 
• Had some fun…
Get-Info “SP PowerShell On-Premises” 
• Uses the Microsoft.SharePoint.PowerShell 
snap-in 
• Access to hundreds* of native cmdlets 
• Script using Server Side Object Model 
Code 
• Run as default (administrative) user 
• Must have server access 
*782 cmdlets on 
my SP 2013 April 
2014 CU farm.
Get-Info “SP PowerShell O365” 
• Uses the 
Microsoft.Online.SharePoint.PowerShell 
module 
• Access to thirty* (30) native cmdlets 
• Script using Client Side Object Model 
Code 
• Provide user credentials for ClientContext 
• No need for server access 
*30 cmdlets as of 
9/19/2014.
Get-Started -with “SP Online Scripting” 
• Download the SharePoint Online 
Management Shell 
• Use Connect-SPOService to connect to 
your Tenant SharePoint Administration 
Site 
• Use Get-Command –Module 
Microsoft.Online.SharePoint.PowerShell to 
see the available cmdlets
Get-Intro –Topic “SharePoint CSOM” 
• Add the following Assemblies 
– Microsoft.SharePoint.Client.dll 
– Microsoft.SharePoint.Client.Runtime.dll 
• Create a Client.Context variable 
• Call the Load() and ExecuteQuery() 
methods 
• Once context is created, get and set 
properties… 
For help on writing 
CSOM, see 
http://bit.ly/MsdnCsom
D E M O 
SharePoint Online
Get-Recap 
• Loaded assemblies using: 
Import-SPOAssemblies 
• Created context using 
New-SPOServiceContext 
• Created a new Site using 
New-SPOWeb 
• Retrieved Web using 
Get-SPOWeb 
• Set Properties with CSOM 
• Created a new List with 
New-SPOList 
Important! 
All of these 
functions/commands 
are a part of our 
custom PowerShell 
Module! Not OOTB.
Get-Info –Type “Bonus” 
• All of this works on-premises as well… 
– Just need to create ClientContext() differently 
• Use the System.Net.NetworkCredential object instead of 
Microsoft.SharePoint.Client.SharePointOnlineCredentials 
• It is security trimmed, if you don’t have SP 
permissions to do this – you can’t… 
• CSOM != SSOM 
– You do not have access to all of the same 
methods and properties…
Q U E S T I O N S ?
Ryan Dennis 
Senior SharePoint Consultant at Blue Chip Consulting Group 
Recently published first book as a co-author 
www.bluechip-llc.com 
ryan.dennis@bluechip-llc.com 
@SharePointRyan 
/in/SharePointRyan 
/SharePointRyanDotCom 
www.sharepointryan.com 
SP Geek Father 
Drummer 
Husband 
Scripter Author

More Related Content

What's hot

Introduction to SharePoint Framework (SPFx)
Introduction to SharePoint Framework (SPFx)Introduction to SharePoint Framework (SPFx)
Introduction to SharePoint Framework (SPFx)Fabio Franzini
 
Introduction to SharePoint Framework
Introduction to SharePoint FrameworkIntroduction to SharePoint Framework
Introduction to SharePoint FrameworkMałgorzata Borzęcka
 
SPSNJ 2014: EmberJS & SharePoint
SPSNJ 2014: EmberJS & SharePointSPSNJ 2014: EmberJS & SharePoint
SPSNJ 2014: EmberJS & SharePointGreg Hurlman
 
Untangling - fall2017 - week5
Untangling - fall2017 - week5Untangling - fall2017 - week5
Untangling - fall2017 - week5Derek Jacoby
 
The future of web development write once, run everywhere with angular.js and ...
The future of web development write once, run everywhere with angular.js and ...The future of web development write once, run everywhere with angular.js and ...
The future of web development write once, run everywhere with angular.js and ...Mark Roden
 
DEV117 - Unleash the Power of the AppDev Pack and Node.js in Domino
DEV117 - Unleash the Power of the AppDev Pack and Node.js in DominoDEV117 - Unleash the Power of the AppDev Pack and Node.js in Domino
DEV117 - Unleash the Power of the AppDev Pack and Node.js in DominoHeiko Voigt
 
Building CLR/H Registration Site with ASP.NET MVC4 and EF4CodeFirst
Building CLR/H Registration Site with ASP.NET MVC4 and EF4CodeFirstBuilding CLR/H Registration Site with ASP.NET MVC4 and EF4CodeFirst
Building CLR/H Registration Site with ASP.NET MVC4 and EF4CodeFirstJun-ichi Sakamoto
 
Engage 2019: Modernising Your Domino and XPages Applications
Engage 2019: Modernising Your Domino and XPages Applications Engage 2019: Modernising Your Domino and XPages Applications
Engage 2019: Modernising Your Domino and XPages Applications Paul Withers
 
SharePoint Framework - Developer Preview
SharePoint Framework - Developer PreviewSharePoint Framework - Developer Preview
SharePoint Framework - Developer PreviewSean McLellan
 
[Patel] SPFx: An ISV Insight into latest Microsoft's customization model
[Patel] SPFx: An ISV Insight into latest Microsoft's customization model[Patel] SPFx: An ISV Insight into latest Microsoft's customization model
[Patel] SPFx: An ISV Insight into latest Microsoft's customization modelEuropean Collaboration Summit
 
Activate bots within SharePoint Framework
Activate bots within SharePoint FrameworkActivate bots within SharePoint Framework
Activate bots within SharePoint FrameworkKushan Lahiru Perera
 
Application Lifecycle Management for Office 365 development
Application Lifecycle Management for Office 365 developmentApplication Lifecycle Management for Office 365 development
Application Lifecycle Management for Office 365 developmentChris O'Brien
 
Contentful with Netgen Layouts workshop
Contentful with Netgen Layouts workshopContentful with Netgen Layouts workshop
Contentful with Netgen Layouts workshopIvo Lukac
 
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)Chris O'Brien
 
Using Chat Automation - ChatOps
Using Chat Automation - ChatOpsUsing Chat Automation - ChatOps
Using Chat Automation - ChatOpsJaap Brasser
 
Spsbe2012 sessie start to-jquery
Spsbe2012 sessie start to-jquerySpsbe2012 sessie start to-jquery
Spsbe2012 sessie start to-jqueryMarijn Somers
 
SUGUK Let me script that for you
SUGUK Let me script that for youSUGUK Let me script that for you
SUGUK Let me script that for yousharepointbaker
 
Front-end tower of Babylon
Front-end tower of BabylonFront-end tower of Babylon
Front-end tower of BabylonDenis Radin
 

What's hot (20)

Introduction to SharePoint Framework (SPFx)
Introduction to SharePoint Framework (SPFx)Introduction to SharePoint Framework (SPFx)
Introduction to SharePoint Framework (SPFx)
 
Introduction to SharePoint Framework
Introduction to SharePoint FrameworkIntroduction to SharePoint Framework
Introduction to SharePoint Framework
 
Iconus 2016
Iconus 2016Iconus 2016
Iconus 2016
 
SPSNJ 2014: EmberJS & SharePoint
SPSNJ 2014: EmberJS & SharePointSPSNJ 2014: EmberJS & SharePoint
SPSNJ 2014: EmberJS & SharePoint
 
Untangling - fall2017 - week5
Untangling - fall2017 - week5Untangling - fall2017 - week5
Untangling - fall2017 - week5
 
The future of web development write once, run everywhere with angular.js and ...
The future of web development write once, run everywhere with angular.js and ...The future of web development write once, run everywhere with angular.js and ...
The future of web development write once, run everywhere with angular.js and ...
 
DEV117 - Unleash the Power of the AppDev Pack and Node.js in Domino
DEV117 - Unleash the Power of the AppDev Pack and Node.js in DominoDEV117 - Unleash the Power of the AppDev Pack and Node.js in Domino
DEV117 - Unleash the Power of the AppDev Pack and Node.js in Domino
 
Building CLR/H Registration Site with ASP.NET MVC4 and EF4CodeFirst
Building CLR/H Registration Site with ASP.NET MVC4 and EF4CodeFirstBuilding CLR/H Registration Site with ASP.NET MVC4 and EF4CodeFirst
Building CLR/H Registration Site with ASP.NET MVC4 and EF4CodeFirst
 
Engage 2019: Modernising Your Domino and XPages Applications
Engage 2019: Modernising Your Domino and XPages Applications Engage 2019: Modernising Your Domino and XPages Applications
Engage 2019: Modernising Your Domino and XPages Applications
 
SharePoint Framework - Developer Preview
SharePoint Framework - Developer PreviewSharePoint Framework - Developer Preview
SharePoint Framework - Developer Preview
 
Go with the flow!
Go with the flow!Go with the flow!
Go with the flow!
 
[Patel] SPFx: An ISV Insight into latest Microsoft's customization model
[Patel] SPFx: An ISV Insight into latest Microsoft's customization model[Patel] SPFx: An ISV Insight into latest Microsoft's customization model
[Patel] SPFx: An ISV Insight into latest Microsoft's customization model
 
Activate bots within SharePoint Framework
Activate bots within SharePoint FrameworkActivate bots within SharePoint Framework
Activate bots within SharePoint Framework
 
Application Lifecycle Management for Office 365 development
Application Lifecycle Management for Office 365 developmentApplication Lifecycle Management for Office 365 development
Application Lifecycle Management for Office 365 development
 
Contentful with Netgen Layouts workshop
Contentful with Netgen Layouts workshopContentful with Netgen Layouts workshop
Contentful with Netgen Layouts workshop
 
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)
 
Using Chat Automation - ChatOps
Using Chat Automation - ChatOpsUsing Chat Automation - ChatOps
Using Chat Automation - ChatOps
 
Spsbe2012 sessie start to-jquery
Spsbe2012 sessie start to-jquerySpsbe2012 sessie start to-jquery
Spsbe2012 sessie start to-jquery
 
SUGUK Let me script that for you
SUGUK Let me script that for youSUGUK Let me script that for you
SUGUK Let me script that for you
 
Front-end tower of Babylon
Front-end tower of BabylonFront-end tower of Babylon
Front-end tower of Babylon
 

Viewers also liked

Don't be afraid of moving infrastructure into Azure!
Don't be afraid of moving infrastructure into Azure!Don't be afraid of moving infrastructure into Azure!
Don't be afraid of moving infrastructure into Azure!Ryan Dennis
 
Leave the fileshare, and join the enterprise content revolution!
Leave the fileshare, and join the enterprise content revolution!Leave the fileshare, and join the enterprise content revolution!
Leave the fileshare, and join the enterprise content revolution!Ryan Dennis
 
Leave the Fileshare, and join the Enterprise Content Revolution!
Leave the Fileshare, and join the Enterprise Content Revolution!Leave the Fileshare, and join the Enterprise Content Revolution!
Leave the Fileshare, and join the Enterprise Content Revolution!Ryan Dennis
 
Herding CATS: Gaining user adoption with these 4 principles
Herding CATS: Gaining user adoption with these 4 principlesHerding CATS: Gaining user adoption with these 4 principles
Herding CATS: Gaining user adoption with these 4 principlesRyan Dennis
 
So You Want To Be A SharePoint Developer-SPS Silicon Valley 2015
So You Want To Be A SharePoint Developer-SPS Silicon Valley 2015So You Want To Be A SharePoint Developer-SPS Silicon Valley 2015
So You Want To Be A SharePoint Developer-SPS Silicon Valley 2015Ryan Schouten
 
Intro to SharePoint + PowerShell
Intro to SharePoint + PowerShellIntro to SharePoint + PowerShell
Intro to SharePoint + PowerShellRyan Dennis
 
So You Want to Be a SharePoint Developer - SPS Utah 2015
So You Want to Be a SharePoint Developer - SPS Utah 2015So You Want to Be a SharePoint Developer - SPS Utah 2015
So You Want to Be a SharePoint Developer - SPS Utah 2015Ryan Schouten
 
SharePoint Saturday Silicon Valley - SharePoint Apps - Ryan Schouten
SharePoint Saturday Silicon Valley - SharePoint Apps - Ryan SchoutenSharePoint Saturday Silicon Valley - SharePoint Apps - Ryan Schouten
SharePoint Saturday Silicon Valley - SharePoint Apps - Ryan SchoutenRyan Schouten
 
SharePoint Online App Model Guidance
SharePoint Online App Model GuidanceSharePoint Online App Model Guidance
SharePoint Online App Model GuidanceRyan Berg
 
Using office add ins to solve business problems-SharePoint Saturday Redmond 2015
Using office add ins to solve business problems-SharePoint Saturday Redmond 2015Using office add ins to solve business problems-SharePoint Saturday Redmond 2015
Using office add ins to solve business problems-SharePoint Saturday Redmond 2015Ryan Schouten
 

Viewers also liked (10)

Don't be afraid of moving infrastructure into Azure!
Don't be afraid of moving infrastructure into Azure!Don't be afraid of moving infrastructure into Azure!
Don't be afraid of moving infrastructure into Azure!
 
Leave the fileshare, and join the enterprise content revolution!
Leave the fileshare, and join the enterprise content revolution!Leave the fileshare, and join the enterprise content revolution!
Leave the fileshare, and join the enterprise content revolution!
 
Leave the Fileshare, and join the Enterprise Content Revolution!
Leave the Fileshare, and join the Enterprise Content Revolution!Leave the Fileshare, and join the Enterprise Content Revolution!
Leave the Fileshare, and join the Enterprise Content Revolution!
 
Herding CATS: Gaining user adoption with these 4 principles
Herding CATS: Gaining user adoption with these 4 principlesHerding CATS: Gaining user adoption with these 4 principles
Herding CATS: Gaining user adoption with these 4 principles
 
So You Want To Be A SharePoint Developer-SPS Silicon Valley 2015
So You Want To Be A SharePoint Developer-SPS Silicon Valley 2015So You Want To Be A SharePoint Developer-SPS Silicon Valley 2015
So You Want To Be A SharePoint Developer-SPS Silicon Valley 2015
 
Intro to SharePoint + PowerShell
Intro to SharePoint + PowerShellIntro to SharePoint + PowerShell
Intro to SharePoint + PowerShell
 
So You Want to Be a SharePoint Developer - SPS Utah 2015
So You Want to Be a SharePoint Developer - SPS Utah 2015So You Want to Be a SharePoint Developer - SPS Utah 2015
So You Want to Be a SharePoint Developer - SPS Utah 2015
 
SharePoint Saturday Silicon Valley - SharePoint Apps - Ryan Schouten
SharePoint Saturday Silicon Valley - SharePoint Apps - Ryan SchoutenSharePoint Saturday Silicon Valley - SharePoint Apps - Ryan Schouten
SharePoint Saturday Silicon Valley - SharePoint Apps - Ryan Schouten
 
SharePoint Online App Model Guidance
SharePoint Online App Model GuidanceSharePoint Online App Model Guidance
SharePoint Online App Model Guidance
 
Using office add ins to solve business problems-SharePoint Saturday Redmond 2015
Using office add ins to solve business problems-SharePoint Saturday Redmond 2015Using office add ins to solve business problems-SharePoint Saturday Redmond 2015
Using office add ins to solve business problems-SharePoint Saturday Redmond 2015
 

Similar to SharePoint Saturday Cincinnati 2014 - CSOM

SharePoint PowerShell for the Admin and Developer - A Venn Diagram Experience
SharePoint PowerShell for the Admin and Developer - A Venn Diagram ExperienceSharePoint PowerShell for the Admin and Developer - A Venn Diagram Experience
SharePoint PowerShell for the Admin and Developer - A Venn Diagram ExperienceRicardo Wilkins
 
Spsatx slides (widescreen)
Spsatx slides (widescreen)Spsatx slides (widescreen)
Spsatx slides (widescreen)Ryan Dennis
 
PowerShell for the Anxious ITPro
PowerShell for the Anxious ITProPowerShell for the Anxious ITPro
PowerShell for the Anxious ITProJason Himmelstein
 
Introduction to Office Development Topics
Introduction to Office Development TopicsIntroduction to Office Development Topics
Introduction to Office Development TopicsHaaron Gonzalez
 
M365 global developer bootcamp 2019 Intro to SPFx Version
M365 global developer bootcamp 2019 Intro to SPFx VersionM365 global developer bootcamp 2019 Intro to SPFx Version
M365 global developer bootcamp 2019 Intro to SPFx VersionThomas Daly
 
Power shell for sp admins
Power shell for sp adminsPower shell for sp admins
Power shell for sp adminsRick Taylor
 
Introduction to PowerShell for SharePoint Admins and Developers
Introduction to PowerShell for SharePoint Admins and DevelopersIntroduction to PowerShell for SharePoint Admins and Developers
Introduction to PowerShell for SharePoint Admins and DevelopersMichael Blumenthal (Microsoft MVP)
 
Connect 2014 SHOW102: XPages Still No Experience Necessary
Connect 2014 SHOW102: XPages Still No Experience NecessaryConnect 2014 SHOW102: XPages Still No Experience Necessary
Connect 2014 SHOW102: XPages Still No Experience Necessarypanagenda
 
PowerShell Basics for Office Apps and Servers
PowerShell Basics for Office Apps and ServersPowerShell Basics for Office Apps and Servers
PowerShell Basics for Office Apps and ServersGreg McMurray
 
Thoughts on building deployable and updatable share point solutions
Thoughts on building deployable and updatable share point solutionsThoughts on building deployable and updatable share point solutions
Thoughts on building deployable and updatable share point solutionsSerge van den Oever
 
Building Chatbots
Building ChatbotsBuilding Chatbots
Building ChatbotsTessa Mero
 
PowerShell for the Hybrid Admin
PowerShell for the Hybrid AdminPowerShell for the Hybrid Admin
PowerShell for the Hybrid AdminJason Himmelstein
 
I6 - State of the art SharePoint PowerShell Nation 2017 - Spencer Harbar
I6 - State of the art SharePoint PowerShell Nation 2017 - Spencer HarbarI6 - State of the art SharePoint PowerShell Nation 2017 - Spencer Harbar
I6 - State of the art SharePoint PowerShell Nation 2017 - Spencer HarbarSPS Paris
 
Learn from my Mistakes - Building Better Solutions in SPFx
Learn from my  Mistakes - Building Better Solutions in SPFxLearn from my  Mistakes - Building Better Solutions in SPFx
Learn from my Mistakes - Building Better Solutions in SPFxThomas Daly
 
SPugPt Meeting 35: Manage govern and drive adoption of share point online wit...
SPugPt Meeting 35: Manage govern and drive adoption of share point online wit...SPugPt Meeting 35: Manage govern and drive adoption of share point online wit...
SPugPt Meeting 35: Manage govern and drive adoption of share point online wit...Comunidade Portuguesa de SharePoiint
 
Empowering Business Users with Flexible SharePoint Customization
Empowering Business Users with Flexible SharePoint Customization Empowering Business Users with Flexible SharePoint Customization
Empowering Business Users with Flexible SharePoint Customization D'arce Hess
 
Move past bootstrap and build our lightweight responsive framework w.v1.2
Move past bootstrap and build our lightweight responsive framework w.v1.2Move past bootstrap and build our lightweight responsive framework w.v1.2
Move past bootstrap and build our lightweight responsive framework w.v1.2Eric Overfield
 
[Pinto] Is my SharePoint Development team properly enlighted?
[Pinto] Is my SharePoint Development team properly enlighted?[Pinto] Is my SharePoint Development team properly enlighted?
[Pinto] Is my SharePoint Development team properly enlighted?European Collaboration Summit
 
I5 - Bring yourself up to speed with power shell
I5 -  Bring yourself up to speed with power shellI5 -  Bring yourself up to speed with power shell
I5 - Bring yourself up to speed with power shellSPS Paris
 

Similar to SharePoint Saturday Cincinnati 2014 - CSOM (20)

SharePoint PowerShell for the Admin and Developer - A Venn Diagram Experience
SharePoint PowerShell for the Admin and Developer - A Venn Diagram ExperienceSharePoint PowerShell for the Admin and Developer - A Venn Diagram Experience
SharePoint PowerShell for the Admin and Developer - A Venn Diagram Experience
 
Spsatx slides (widescreen)
Spsatx slides (widescreen)Spsatx slides (widescreen)
Spsatx slides (widescreen)
 
PowerShell for the Anxious ITPro
PowerShell for the Anxious ITProPowerShell for the Anxious ITPro
PowerShell for the Anxious ITPro
 
Introduction to Office Development Topics
Introduction to Office Development TopicsIntroduction to Office Development Topics
Introduction to Office Development Topics
 
Introducción al SharePoint Framework SPFx
Introducción al SharePoint Framework SPFxIntroducción al SharePoint Framework SPFx
Introducción al SharePoint Framework SPFx
 
M365 global developer bootcamp 2019 Intro to SPFx Version
M365 global developer bootcamp 2019 Intro to SPFx VersionM365 global developer bootcamp 2019 Intro to SPFx Version
M365 global developer bootcamp 2019 Intro to SPFx Version
 
Power shell for sp admins
Power shell for sp adminsPower shell for sp admins
Power shell for sp admins
 
Introduction to PowerShell for SharePoint Admins and Developers
Introduction to PowerShell for SharePoint Admins and DevelopersIntroduction to PowerShell for SharePoint Admins and Developers
Introduction to PowerShell for SharePoint Admins and Developers
 
Connect 2014 SHOW102: XPages Still No Experience Necessary
Connect 2014 SHOW102: XPages Still No Experience NecessaryConnect 2014 SHOW102: XPages Still No Experience Necessary
Connect 2014 SHOW102: XPages Still No Experience Necessary
 
PowerShell Basics for Office Apps and Servers
PowerShell Basics for Office Apps and ServersPowerShell Basics for Office Apps and Servers
PowerShell Basics for Office Apps and Servers
 
Thoughts on building deployable and updatable share point solutions
Thoughts on building deployable and updatable share point solutionsThoughts on building deployable and updatable share point solutions
Thoughts on building deployable and updatable share point solutions
 
Building Chatbots
Building ChatbotsBuilding Chatbots
Building Chatbots
 
PowerShell for the Hybrid Admin
PowerShell for the Hybrid AdminPowerShell for the Hybrid Admin
PowerShell for the Hybrid Admin
 
I6 - State of the art SharePoint PowerShell Nation 2017 - Spencer Harbar
I6 - State of the art SharePoint PowerShell Nation 2017 - Spencer HarbarI6 - State of the art SharePoint PowerShell Nation 2017 - Spencer Harbar
I6 - State of the art SharePoint PowerShell Nation 2017 - Spencer Harbar
 
Learn from my Mistakes - Building Better Solutions in SPFx
Learn from my  Mistakes - Building Better Solutions in SPFxLearn from my  Mistakes - Building Better Solutions in SPFx
Learn from my Mistakes - Building Better Solutions in SPFx
 
SPugPt Meeting 35: Manage govern and drive adoption of share point online wit...
SPugPt Meeting 35: Manage govern and drive adoption of share point online wit...SPugPt Meeting 35: Manage govern and drive adoption of share point online wit...
SPugPt Meeting 35: Manage govern and drive adoption of share point online wit...
 
Empowering Business Users with Flexible SharePoint Customization
Empowering Business Users with Flexible SharePoint Customization Empowering Business Users with Flexible SharePoint Customization
Empowering Business Users with Flexible SharePoint Customization
 
Move past bootstrap and build our lightweight responsive framework w.v1.2
Move past bootstrap and build our lightweight responsive framework w.v1.2Move past bootstrap and build our lightweight responsive framework w.v1.2
Move past bootstrap and build our lightweight responsive framework w.v1.2
 
[Pinto] Is my SharePoint Development team properly enlighted?
[Pinto] Is my SharePoint Development team properly enlighted?[Pinto] Is my SharePoint Development team properly enlighted?
[Pinto] Is my SharePoint Development team properly enlighted?
 
I5 - Bring yourself up to speed with power shell
I5 -  Bring yourself up to speed with power shellI5 -  Bring yourself up to speed with power shell
I5 - Bring yourself up to speed with power shell
 

More from Ryan Dennis

Leave The Fileshare and join the Enterprise Content Revolution!
Leave The Fileshare and join the Enterprise Content Revolution!Leave The Fileshare and join the Enterprise Content Revolution!
Leave The Fileshare and join the Enterprise Content Revolution!Ryan Dennis
 
SPSCBUS Slides Scarlet InfoPath
SPSCBUS Slides Scarlet InfoPathSPSCBUS Slides Scarlet InfoPath
SPSCBUS Slides Scarlet InfoPathRyan Dennis
 
Dogfood slides 2012
Dogfood slides 2012Dogfood slides 2012
Dogfood slides 2012Ryan Dennis
 
ScarePoint Saturday Spookinnati Slides
ScarePoint Saturday Spookinnati SlidesScarePoint Saturday Spookinnati Slides
ScarePoint Saturday Spookinnati SlidesRyan Dennis
 
DAYSPUG - Funnel your info down a new path
DAYSPUG - Funnel your info down a new pathDAYSPUG - Funnel your info down a new path
DAYSPUG - Funnel your info down a new pathRyan Dennis
 
Build your SharePoint Internet Presence with PowerShell
Build your SharePoint Internet Presence with PowerShellBuild your SharePoint Internet Presence with PowerShell
Build your SharePoint Internet Presence with PowerShellRyan Dennis
 
Funnel your Info down a new Path
Funnel your Info down a new PathFunnel your Info down a new Path
Funnel your Info down a new PathRyan Dennis
 
SPS Dayton Slides
SPS Dayton SlidesSPS Dayton Slides
SPS Dayton SlidesRyan Dennis
 
SPS Cincinnati slidedeck (pdf)
SPS Cincinnati slidedeck (pdf)SPS Cincinnati slidedeck (pdf)
SPS Cincinnati slidedeck (pdf)Ryan Dennis
 
SPS Cincinnati slidedeck
SPS Cincinnati slidedeckSPS Cincinnati slidedeck
SPS Cincinnati slidedeckRyan Dennis
 

More from Ryan Dennis (10)

Leave The Fileshare and join the Enterprise Content Revolution!
Leave The Fileshare and join the Enterprise Content Revolution!Leave The Fileshare and join the Enterprise Content Revolution!
Leave The Fileshare and join the Enterprise Content Revolution!
 
SPSCBUS Slides Scarlet InfoPath
SPSCBUS Slides Scarlet InfoPathSPSCBUS Slides Scarlet InfoPath
SPSCBUS Slides Scarlet InfoPath
 
Dogfood slides 2012
Dogfood slides 2012Dogfood slides 2012
Dogfood slides 2012
 
ScarePoint Saturday Spookinnati Slides
ScarePoint Saturday Spookinnati SlidesScarePoint Saturday Spookinnati Slides
ScarePoint Saturday Spookinnati Slides
 
DAYSPUG - Funnel your info down a new path
DAYSPUG - Funnel your info down a new pathDAYSPUG - Funnel your info down a new path
DAYSPUG - Funnel your info down a new path
 
Build your SharePoint Internet Presence with PowerShell
Build your SharePoint Internet Presence with PowerShellBuild your SharePoint Internet Presence with PowerShell
Build your SharePoint Internet Presence with PowerShell
 
Funnel your Info down a new Path
Funnel your Info down a new PathFunnel your Info down a new Path
Funnel your Info down a new Path
 
SPS Dayton Slides
SPS Dayton SlidesSPS Dayton Slides
SPS Dayton Slides
 
SPS Cincinnati slidedeck (pdf)
SPS Cincinnati slidedeck (pdf)SPS Cincinnati slidedeck (pdf)
SPS Cincinnati slidedeck (pdf)
 
SPS Cincinnati slidedeck
SPS Cincinnati slidedeckSPS Cincinnati slidedeck
SPS Cincinnati slidedeck
 

Recently uploaded

Tech-Forward - Achieving Business Readiness For Copilot in Microsoft 365
Tech-Forward - Achieving Business Readiness For Copilot in Microsoft 365Tech-Forward - Achieving Business Readiness For Copilot in Microsoft 365
Tech-Forward - Achieving Business Readiness For Copilot in Microsoft 3652toLead Limited
 
How to convert PDF to text with Nanonets
How to convert PDF to text with NanonetsHow to convert PDF to text with Nanonets
How to convert PDF to text with Nanonetsnaman860154
 
Injustice - Developers Among Us (SciFiDevCon 2024)
Injustice - Developers Among Us (SciFiDevCon 2024)Injustice - Developers Among Us (SciFiDevCon 2024)
Injustice - Developers Among Us (SciFiDevCon 2024)Allon Mureinik
 
How to Remove Document Management Hurdles with X-Docs?
How to Remove Document Management Hurdles with X-Docs?How to Remove Document Management Hurdles with X-Docs?
How to Remove Document Management Hurdles with X-Docs?XfilesPro
 
Pigging Solutions in Pet Food Manufacturing
Pigging Solutions in Pet Food ManufacturingPigging Solutions in Pet Food Manufacturing
Pigging Solutions in Pet Food ManufacturingPigging Solutions
 
Slack Application Development 101 Slides
Slack Application Development 101 SlidesSlack Application Development 101 Slides
Slack Application Development 101 Slidespraypatel2
 
Maximizing Board Effectiveness 2024 Webinar.pptx
Maximizing Board Effectiveness 2024 Webinar.pptxMaximizing Board Effectiveness 2024 Webinar.pptx
Maximizing Board Effectiveness 2024 Webinar.pptxOnBoard
 
Neo4j - How KGs are shaping the future of Generative AI at AWS Summit London ...
Neo4j - How KGs are shaping the future of Generative AI at AWS Summit London ...Neo4j - How KGs are shaping the future of Generative AI at AWS Summit London ...
Neo4j - How KGs are shaping the future of Generative AI at AWS Summit London ...Neo4j
 
Install Stable Diffusion in windows machine
Install Stable Diffusion in windows machineInstall Stable Diffusion in windows machine
Install Stable Diffusion in windows machinePadma Pradeep
 
Next-generation AAM aircraft unveiled by Supernal, S-A2
Next-generation AAM aircraft unveiled by Supernal, S-A2Next-generation AAM aircraft unveiled by Supernal, S-A2
Next-generation AAM aircraft unveiled by Supernal, S-A2Hyundai Motor Group
 
GenCyber Cyber Security Day Presentation
GenCyber Cyber Security Day PresentationGenCyber Cyber Security Day Presentation
GenCyber Cyber Security Day PresentationMichael W. Hawkins
 
Presentation on how to chat with PDF using ChatGPT code interpreter
Presentation on how to chat with PDF using ChatGPT code interpreterPresentation on how to chat with PDF using ChatGPT code interpreter
Presentation on how to chat with PDF using ChatGPT code interpreternaman860154
 
AI as an Interface for Commercial Buildings
AI as an Interface for Commercial BuildingsAI as an Interface for Commercial Buildings
AI as an Interface for Commercial BuildingsMemoori
 
Transforming Data Streams with Kafka Connect: An Introduction to Single Messa...
Transforming Data Streams with Kafka Connect: An Introduction to Single Messa...Transforming Data Streams with Kafka Connect: An Introduction to Single Messa...
Transforming Data Streams with Kafka Connect: An Introduction to Single Messa...HostedbyConfluent
 
SQL Database Design For Developers at php[tek] 2024
SQL Database Design For Developers at php[tek] 2024SQL Database Design For Developers at php[tek] 2024
SQL Database Design For Developers at php[tek] 2024Scott Keck-Warren
 
Benefits Of Flutter Compared To Other Frameworks
Benefits Of Flutter Compared To Other FrameworksBenefits Of Flutter Compared To Other Frameworks
Benefits Of Flutter Compared To Other FrameworksSoftradix Technologies
 
Understanding the Laravel MVC Architecture
Understanding the Laravel MVC ArchitectureUnderstanding the Laravel MVC Architecture
Understanding the Laravel MVC ArchitecturePixlogix Infotech
 
Human Factors of XR: Using Human Factors to Design XR Systems
Human Factors of XR: Using Human Factors to Design XR SystemsHuman Factors of XR: Using Human Factors to Design XR Systems
Human Factors of XR: Using Human Factors to Design XR SystemsMark Billinghurst
 
SIEMENS: RAPUNZEL – A Tale About Knowledge Graph
SIEMENS: RAPUNZEL – A Tale About Knowledge GraphSIEMENS: RAPUNZEL – A Tale About Knowledge Graph
SIEMENS: RAPUNZEL – A Tale About Knowledge GraphNeo4j
 

Recently uploaded (20)

Tech-Forward - Achieving Business Readiness For Copilot in Microsoft 365
Tech-Forward - Achieving Business Readiness For Copilot in Microsoft 365Tech-Forward - Achieving Business Readiness For Copilot in Microsoft 365
Tech-Forward - Achieving Business Readiness For Copilot in Microsoft 365
 
How to convert PDF to text with Nanonets
How to convert PDF to text with NanonetsHow to convert PDF to text with Nanonets
How to convert PDF to text with Nanonets
 
Injustice - Developers Among Us (SciFiDevCon 2024)
Injustice - Developers Among Us (SciFiDevCon 2024)Injustice - Developers Among Us (SciFiDevCon 2024)
Injustice - Developers Among Us (SciFiDevCon 2024)
 
How to Remove Document Management Hurdles with X-Docs?
How to Remove Document Management Hurdles with X-Docs?How to Remove Document Management Hurdles with X-Docs?
How to Remove Document Management Hurdles with X-Docs?
 
Pigging Solutions in Pet Food Manufacturing
Pigging Solutions in Pet Food ManufacturingPigging Solutions in Pet Food Manufacturing
Pigging Solutions in Pet Food Manufacturing
 
Slack Application Development 101 Slides
Slack Application Development 101 SlidesSlack Application Development 101 Slides
Slack Application Development 101 Slides
 
Maximizing Board Effectiveness 2024 Webinar.pptx
Maximizing Board Effectiveness 2024 Webinar.pptxMaximizing Board Effectiveness 2024 Webinar.pptx
Maximizing Board Effectiveness 2024 Webinar.pptx
 
Neo4j - How KGs are shaping the future of Generative AI at AWS Summit London ...
Neo4j - How KGs are shaping the future of Generative AI at AWS Summit London ...Neo4j - How KGs are shaping the future of Generative AI at AWS Summit London ...
Neo4j - How KGs are shaping the future of Generative AI at AWS Summit London ...
 
Install Stable Diffusion in windows machine
Install Stable Diffusion in windows machineInstall Stable Diffusion in windows machine
Install Stable Diffusion in windows machine
 
Next-generation AAM aircraft unveiled by Supernal, S-A2
Next-generation AAM aircraft unveiled by Supernal, S-A2Next-generation AAM aircraft unveiled by Supernal, S-A2
Next-generation AAM aircraft unveiled by Supernal, S-A2
 
GenCyber Cyber Security Day Presentation
GenCyber Cyber Security Day PresentationGenCyber Cyber Security Day Presentation
GenCyber Cyber Security Day Presentation
 
Presentation on how to chat with PDF using ChatGPT code interpreter
Presentation on how to chat with PDF using ChatGPT code interpreterPresentation on how to chat with PDF using ChatGPT code interpreter
Presentation on how to chat with PDF using ChatGPT code interpreter
 
AI as an Interface for Commercial Buildings
AI as an Interface for Commercial BuildingsAI as an Interface for Commercial Buildings
AI as an Interface for Commercial Buildings
 
Transforming Data Streams with Kafka Connect: An Introduction to Single Messa...
Transforming Data Streams with Kafka Connect: An Introduction to Single Messa...Transforming Data Streams with Kafka Connect: An Introduction to Single Messa...
Transforming Data Streams with Kafka Connect: An Introduction to Single Messa...
 
The transition to renewables in India.pdf
The transition to renewables in India.pdfThe transition to renewables in India.pdf
The transition to renewables in India.pdf
 
SQL Database Design For Developers at php[tek] 2024
SQL Database Design For Developers at php[tek] 2024SQL Database Design For Developers at php[tek] 2024
SQL Database Design For Developers at php[tek] 2024
 
Benefits Of Flutter Compared To Other Frameworks
Benefits Of Flutter Compared To Other FrameworksBenefits Of Flutter Compared To Other Frameworks
Benefits Of Flutter Compared To Other Frameworks
 
Understanding the Laravel MVC Architecture
Understanding the Laravel MVC ArchitectureUnderstanding the Laravel MVC Architecture
Understanding the Laravel MVC Architecture
 
Human Factors of XR: Using Human Factors to Design XR Systems
Human Factors of XR: Using Human Factors to Design XR SystemsHuman Factors of XR: Using Human Factors to Design XR Systems
Human Factors of XR: Using Human Factors to Design XR Systems
 
SIEMENS: RAPUNZEL – A Tale About Knowledge Graph
SIEMENS: RAPUNZEL – A Tale About Knowledge GraphSIEMENS: RAPUNZEL – A Tale About Knowledge Graph
SIEMENS: RAPUNZEL – A Tale About Knowledge Graph
 

SharePoint Saturday Cincinnati 2014 - CSOM

  • 1. Managing SharePoint Anywhere with Windows PowerHell Ryan Dennis
  • 2.
  • 3. Join us for SharePint Location: Sharonville Convention Center Follow the SIGNS if you dare Sponsored by Accusoft & Focal Point Solutions
  • 4. Sponsor s Platinum: Gold: Bronze:
  • 5. Let’s Get Social ! Twitter: @spscincinnati #spspookinnati Mobile: www.spsmobile.com Check us out on Facebook: https://www.facebook.com/spscincy
  • 6. Submit your feedback! He was awesome! me@somewhere.com
  • 7. Ryan Dennis Senior SharePoint Consultant at Blue Chip Consulting Group Recently published first book as a co-author www.bluechip-llc.com ryan.dennis@bluechip-llc.com @SharePointRyan /in/SharePointRyan /SharePointRyanDotCom www.sharepointryan.com SP Geek Father Drummer Husband Scripter Author
  • 8. Get-Agenda • Housekeeping • Intro to Advanced Functions • SharePoint PowerShell On-Premise • SharePoint PowerShell in Office 365 • Using Client Side Object Model (CSOM) code in PowerShell • Q&A
  • 9. Get-Help –Topic “PowerShell” …is a task-based command-line shell and scripting language designed especially for Windows system administration …has a task-based scripting language …includes powerful object manipulation capabilities …is built on the .NET Framework
  • 10. Verb-Noun PowerShell uses a Verb-Noun syntax for its Cmdlets • Get-Something • Set-Something • New-Something • Remove-Something Quick Tip! Use Get-Verb to find approved verbs! Use Verb-Noun in your code!
  • 11. Get-Command & Get-Help • Use Get-Command to see available commands Get-Command –Module Microsoft.SharePoint.PowerShell Get-Command –Module Microsoft.Online.SharePoint.PowerShell • Use Get-Help <CmdletName> to get help information for a cmdlet Quick Tip! Add Help to your scripts and functions!
  • 12. Get-Command –Type “SharePoint” • SharePoint 2010 – 500+ Cmdlets… – MUCH better than STSADM.exe in prior versions… – Can automate complete installations and configurations… • SharePoint 2013 – 700+ Cmdlets! • Still doesn’t answer every scenario, leaving gaps in functionality… – Example: Get, New and Remove SharePoint Groups – no cmdlet, easy to write a custom function though… Opportunity! Write our own scripts and functions!
  • 13. Get-Help About_Functions_Advanced …allow you to perform operations that are similar to the operations you can perform with cmdlets …quickly write a function without having to write a compiled cmdlet using a Microsoft .NET Framework language (C#) …use the CmdletBinding() attribute to identify them as functions that act similar to cmdlets Quick Tip! Use Get-Help About_Functions_Advanced for more info!
  • 14. New-Function –Name “Our First Function” • Leverages all of the Write-* cmdlets in the Microsoft.PowerShell.Utility module • Includes Switch statement, ValidateSet, Try/Catch/Finally, etc. • Includes comment-based-help with examples • Can be run just like a cmdlet Disclaimer! This is NOT a SharePoint demo, just a general PowerShell demo!
  • 15. D E M O Write-Message
  • 16. Get-Recap • Reviewed Write-Message function… • Created output using all Write* types • Saw the behavior of –Verbose and –Debug switches • Had some fun…
  • 17.
  • 18. Get-Info “SP PowerShell On-Premises” • Uses the Microsoft.SharePoint.PowerShell snap-in • Access to hundreds* of native cmdlets • Script using Server Side Object Model Code • Run as default (administrative) user • Must have server access *782 cmdlets on my SP 2013 April 2014 CU farm.
  • 19. Get-Info “SP PowerShell O365” • Uses the Microsoft.Online.SharePoint.PowerShell module • Access to thirty* (30) native cmdlets • Script using Client Side Object Model Code • Provide user credentials for ClientContext • No need for server access *30 cmdlets as of 9/19/2014.
  • 20. Get-Started -with “SP Online Scripting” • Download the SharePoint Online Management Shell • Use Connect-SPOService to connect to your Tenant SharePoint Administration Site • Use Get-Command –Module Microsoft.Online.SharePoint.PowerShell to see the available cmdlets
  • 21. Get-Intro –Topic “SharePoint CSOM” • Add the following Assemblies – Microsoft.SharePoint.Client.dll – Microsoft.SharePoint.Client.Runtime.dll • Create a Client.Context variable • Call the Load() and ExecuteQuery() methods • Once context is created, get and set properties… For help on writing CSOM, see http://bit.ly/MsdnCsom
  • 22. D E M O SharePoint Online
  • 23. Get-Recap • Loaded assemblies using: Import-SPOAssemblies • Created context using New-SPOServiceContext • Created a new Site using New-SPOWeb • Retrieved Web using Get-SPOWeb • Set Properties with CSOM • Created a new List with New-SPOList Important! All of these functions/commands are a part of our custom PowerShell Module! Not OOTB.
  • 24. Get-Info –Type “Bonus” • All of this works on-premises as well… – Just need to create ClientContext() differently • Use the System.Net.NetworkCredential object instead of Microsoft.SharePoint.Client.SharePointOnlineCredentials • It is security trimmed, if you don’t have SP permissions to do this – you can’t… • CSOM != SSOM – You do not have access to all of the same methods and properties…
  • 25. Q U E S T I O N S ?
  • 26. Ryan Dennis Senior SharePoint Consultant at Blue Chip Consulting Group Recently published first book as a co-author www.bluechip-llc.com ryan.dennis@bluechip-llc.com @SharePointRyan /in/SharePointRyan /SharePointRyanDotCom www.sharepointryan.com SP Geek Father Drummer Husband Scripter Author

Editor's Notes

  1. Go to the BI Center Excel Services Visio Services
  2. -Show an existing discussion with multiple replies -Create a new discussion -