diff --git a/Content Types/Create/Create content type and add directly to SPO list/description.md b/Content Types/Create/Create content type and add directly to SPO list/description.md
index 0178bdc2..ca9aca82 100644
--- a/Content Types/Create/Create content type and add directly to SPO list/description.md
+++ b/Content Types/Create/Create content type and add directly to SPO list/description.md
@@ -2,19 +2,13 @@ A short script to create a content type, and add it directly to a SharePoint Onl
-The script is fully described in an article here:
-
-http://social.technet.microsoft.com/wiki/contents/articles/31051.sharepoint-online-content-types-in-powershell.aspx
-
-
-
+The script is fully described in an article [here](http://social.technet.microsoft.com/wiki/contents/articles/31051.sharepoint-online-content-types-in-powershell.aspx).
### How to use?
+1. Download and install [SharePoint Online SDK](https://www.microsoft.com/en-us/download/details.aspx?id=42038).
-1. Download and install SharePoint Online SDK.
-
-2. Download the .ps1 file.
+2. Download the *.ps1* file.
3. Open the file (you can do it also in NotePad)
@@ -36,17 +30,15 @@ $ParentContentTypeID="0x01"
$Group="List Content Types"
```
-a) Find on your computer where SharePoint.Clitent.dll and SharePoint.Client.Runtime.dll libraries are located and insert the correct paths
-b) Instead of "admin@tenant.onmicrosoft.com" enter you username
-c) Instead of "https://tenant.sharepoint.com/sites/teamsitewithlibraries" enter the name of the site collection where you want to find the content types
-d) Fill in the properties of the content type.
+a) Find on your computer where SharePoint.Clitent.dll and SharePoint.Client.Runtime.dll libraries are located and insert the correct paths
+b) Instead of "admin@tenant.onmicrosoft.com" enter you username
+c) Instead of "https://tenant.sharepoint.com/sites/teamsitewithlibraries" enter the name of the site collection where you want to find the content types
+d) Fill in the properties of the content type.
-
5. Run the script in Powershell (any module).
-6. When the script has executed, Powershell will show a message Content Type Name of the Content Type2 has been added to Url of the Site.
+6. When the script has executed, Powershell will show a message *Content Type Name of the Content Type2 has been added to Url of the Site*.
-
Enjoy and please share feedback!
diff --git a/Content Types/Create/Create content type and add it to all lists in one site/description.md b/Content Types/Create/Create content type and add it to all lists in one site/description.md
index 82f53e3b..9b387e4a 100644
--- a/Content Types/Create/Create content type and add it to all lists in one site/description.md
+++ b/Content Types/Create/Create content type and add it to all lists in one site/description.md
@@ -2,19 +2,13 @@ A short script to create a content type, and add it directly to all SharePoint O
-The script is fully described in an article here:
-
-http://social.technet.microsoft.com/wiki/contents/articles/31051.sharepoint-online-content-types-in-powershell.aspx
-
-
+The script is fully described in an article [here](http://social.technet.microsoft.com/wiki/contents/articles/31051.sharepoint-online-content-types-in-powershell.aspx).
### How to use?
+1. Download and install [SharePoint Online SDK](https://www.microsoft.com/en-us/download/details.aspx?id=42038).
-
-1. Download and install SharePoint Online SDK.
-
-2. Download the .ps1 file.
+2. Download the *.ps1* file.
3. Open the file (you can do it also in NotePad)
@@ -36,16 +30,14 @@ $ParentContentTypeID="0x01"
$Group="List Content Types"
```
-a) Find on your computer where SharePoint.Clitent.dll and SharePoint.Client.Runtime.dll libraries are located and insert the correct paths
-b) Instead of "admin@tenant.onmicrosoft.com" enter you username
-c) Instead of "https://tenant.sharepoint.com/sites/teamsitewithlibraries" enter the name of the site collection where you want to find the content types
-d) Fill in the properties of the content type.
-
+a) Find on your computer where SharePoint.Clitent.dll and SharePoint.Client.Runtime.dll libraries are located and insert the correct paths
+b) Instead of "admin@tenant.onmicrosoft.com" enter you username
+c) Instead of "https://tenant.sharepoint.com/sites/teamsitewithlibraries" enter the name of the site collection where you want to find the content types
+d) Fill in the properties of the content type.
5. Run the script in Powershell (any module).
-6. When the script has executed, Powershell will show a message Content Type Name of the Content Type2 has been added to Title of the List.
-
+6. When the script has executed, Powershell will show a message *Content Type Name of the Content Type2 has been added to Title of the List*.
Enjoy and please share feedback!
diff --git a/Content Types/Display Forms/Find Custom Display Forms Deployed/description.md b/Content Types/Display Forms/Find Custom Display Forms Deployed/description.md
index 1852a4b4..0affd595 100644
--- a/Content Types/Display Forms/Find Custom Display Forms Deployed/description.md
+++ b/Content Types/Display Forms/Find Custom Display Forms Deployed/description.md
@@ -1,20 +1,15 @@
The script is part of the explanation on editing the content types available in the article here:
-SharePoint Online content types in Powershell: Edit.
+[SharePoint Online content types in Powershell: Edit.](https://social.technet.microsoft.com/wiki/contents/articles/31444.sharepoint-online-content-types-in-powershell-edit.aspx)
This example gets the list of all content types in all lists from a single site, which have custom display forms deployed.
-The ~list/Item/displayifs.aspx is the url of the custom form that the list is using for adding new items:
-
-
-
-
-
+The *~list/Item/displayifs.aspx* is the url of the custom form that the list is using for adding new items. (**[screenshot](https://github.com/PowershellScripts/AllGalleryScriptsSamples/blob/develop/Content%20Types/Display%20Forms/Find%20Custom%20Display%20Forms%20Deployed/DisplayFormUrl3.png)**)
-In order to use the script you need SharePoint Online SDK installed. Before running the script modify the following lines to refer to the SDK libraries installed on your computer and the content type data:
+In order to use the script you need [SharePoint Online SDK](https://www.microsoft.com/en-us/download/details.aspx?id=42038) installed. Before running the script modify the following lines to refer to the SDK libraries installed on your computer and the content type data:
@@ -31,4 +26,4 @@ $AdminUrl="https://tenant.sharepoint.com/sites/powie1"
-Enjoy and please share feedback!
\ No newline at end of file
+Enjoy and please share feedback!
diff --git a/Content Types/Display Forms/Modify the Display Form Template Name/description.md b/Content Types/Display Forms/Modify the Display Form Template Name/description.md
index 99e05444..17807251 100644
--- a/Content Types/Display Forms/Modify the Display Form Template Name/description.md
+++ b/Content Types/Display Forms/Modify the Display Form Template Name/description.md
@@ -1,13 +1,13 @@
The script is part of the explanation on editing the content types available in the article here:
-SharePoint Online content types in Powershell: Edit.
+[SharePoint Online content types in Powershell: Edit.](https://social.technet.microsoft.com/wiki/contents/articles/31444.sharepoint-online-content-types-in-powershell-edit.aspx)
-This example gets all content types in a single list from a single site, and changes their display form names,using:
+This example gets all content types in a single list from a single site, and changes their display form names, using:
```PowerShell
$cc.DisplayFormTemplateName="DocumentLibraryForm"
```
-The script requires SharePoint Online SDK installed. Before running the script, enter the information:
+The script requires [SharePoint Online SDK](https://www.microsoft.com/en-us/download/details.aspx?id=42038) installed. Before running the script, enter the information:
```PowerShell
# Paths to SDK. Please verify location on your computer.
@@ -22,4 +22,4 @@ $ListTitle="notf--ked"
```
-Enjoy and please share feedback!
\ No newline at end of file
+Enjoy and please share feedback!
diff --git a/Content Types/Display Forms/Unable to view items- modify the DisplayFormUrl back to default one/description.md b/Content Types/Display Forms/Unable to view items- modify the DisplayFormUrl back to default one/description.md
index 80fe10a5..5b475523 100644
--- a/Content Types/Display Forms/Unable to view items- modify the DisplayFormUrl back to default one/description.md
+++ b/Content Types/Display Forms/Unable to view items- modify the DisplayFormUrl back to default one/description.md
@@ -1,26 +1,13 @@
The script is part of the explanation on editing the content types available in the article here:
-SharePoint Online content types in Powershell: Edit.
+[SharePoint Online content types in Powershell: Edit.](https://social.technet.microsoft.com/wiki/contents/articles/31444.sharepoint-online-content-types-in-powershell-edit.aspx)
This example changes the display form url of all content types called ITEM (so basically all items in a list) in all lists in one site to the default one.
+ It allows us also to retract our changes and turn to the default form in case something went wrong with the Custom form and items are no longer viewable. (**[screenshot](https://github.com/PowershellScripts/AllGalleryScriptsSamples/blob/develop/Content%20Types/Display%20Forms/Unable%20to%20view%20items-%20modify%20the%20DisplayFormUrl%20back%20to%20default%20one/DisplayFormUrl4.png)**)
-
-
- It allows us also to retract our changes and turn to the default form in case something went wrong with the Custom form and items are no longer viewable:
-
-
-
-
-
-
-
-
-
-
-
-In order to use the script you need SharePoint Online SDK installed. Before running the script modify the following lines to refer to the SDK libraries installed on your computer and the content type data:
+In order to use the script you need [SharePoint Online SDK](https://www.microsoft.com/en-us/download/details.aspx?id=42038) installed. Before running the script modify the following lines to refer to the SDK libraries installed on your computer and the content type data:
diff --git a/Content Types/Get/All Content Types from a Content Type Hub and their DisplayFormTemplate/description.md b/Content Types/Get/All Content Types from a Content Type Hub and their DisplayFormTemplate/description.md
index 3138d0ae..aeb4fb1f 100644
--- a/Content Types/Get/All Content Types from a Content Type Hub and their DisplayFormTemplate/description.md
+++ b/Content Types/Get/All Content Types from a Content Type Hub and their DisplayFormTemplate/description.md
@@ -1,22 +1,12 @@
The script is part of the explanation on editing the content types available in the article here:
-SharePoint Online content types in Powershell: Edit.
-
-
-
-This example retrieves all content types from a Content Type Hub, along with their DisplayFormTemplateName property. For instruction how to find a content type hub, you can refer here.
-
-
-
+[SharePoint Online content types in Powershell: Edit.](https://social.technet.microsoft.com/wiki/contents/articles/31444.sharepoint-online-content-types-in-powershell-edit.aspx)
-
+This example retrieves all content types from a Content Type Hub, along with their DisplayFormTemplateName property. For instruction how to find a content type hub, you can refer [here](https://social.technet.microsoft.com/wiki/contents/articles/31051.sharepoint-online-content-types-in-powershell-add.aspx#To_Content_Hub).
-
-
-
-The script requires SharePoint Online SDK installed. Before running the script, enter the information:
+The script requires [SharePoint Online SDK](https://www.microsoft.com/en-us/download/details.aspx?id=42038) installed. Before running the script, enter the information:
```PowerShell
# Paths to SDK. Please verify location on your computer.
@@ -28,9 +18,9 @@ $Username="admin@tenant.onmicrosoft.com"
$AdminPassword=Read-Host -Prompt "Password" -AsSecureString
$AdminUrl="https://tenant.sharepoint.com/sites/contenttypehub"
```
-You can export the results to the CSV or .txt file.
+You can export the results to the CSV or *.txt* file.
-Enjoy and please share feedback!
\ No newline at end of file
+Enjoy and please share feedback!
diff --git a/Content Types/Get/Compare Web.AvailableContentTypes vs Web.ContentTypes/description.md b/Content Types/Get/Compare Web.AvailableContentTypes vs Web.ContentTypes/description.md
index 88ce7072..b46ac438 100644
--- a/Content Types/Get/Compare Web.AvailableContentTypes vs Web.ContentTypes/description.md
+++ b/Content Types/Get/Compare Web.AvailableContentTypes vs Web.ContentTypes/description.md
@@ -2,24 +2,16 @@ Script is part of the explanation of the difference between Web.AvailableContent
-SharePoint Online content types in Powershell: Get
+[SharePoint Online content types in Powershell: Get](https://social.technet.microsoft.com/wiki/contents/articles/31151.sharepoint-online-content-types-in-powershell-get.aspx)
-The script compares the number of items in the two content type collections.
-
-
-
-
-
+The script compares the number of items in the two content type collections. ([screenshot](https://github.com/PowershellScripts/AllGalleryScriptsSamples/blob/develop/Content%20Types/Get/Compare%20Web.AvailableContentTypes%20vs%20Web.ContentTypes/SubsiteCT2.PNG))
Before running, don't forget to open the file and enter your data:
-
-
-
-PowerShell
+```PowerShell
# Paths to SDK. Please verify location on your computer.
Add-Type -Path "c:\Program Files\Common Files\microsoft shared\Web Server Extensions\15\ISAPI\Microsoft.SharePoint.Client.dll"
Add-Type -Path "c:\Program Files\Common Files\microsoft shared\Web Server Extensions\15\ISAPI\Microsoft.SharePoint.Client.Runtime.dll"
@@ -28,7 +20,7 @@ Add-Type -Path "c:\Program Files\Common Files\microsoft shared\Web Server Extens
$Username="admin@tenant.onmicrosoft.com"
$AdminPassword=Read-Host -Prompt "Password" -AsSecureString
$AdminUrl="https://tenant.sharepoint.com/sites/teamsitewithlibraries/subsite"
-
+```
-Enjoy and please share feedback!
\ No newline at end of file
+Enjoy and please share feedback!
diff --git a/Content Types/Get/Find content types added to your lists (recursive)/description.md b/Content Types/Get/Find content types added to your lists (recursive)/description.md
index 4f027eb9..f7f8ef47 100644
--- a/Content Types/Get/Find content types added to your lists (recursive)/description.md
+++ b/Content Types/Get/Find content types added to your lists (recursive)/description.md
@@ -1,9 +1,9 @@
-A short script to find all content types added to all of your lists in a given site collection and its subsites.
+A short script to find all content types added to all of your lists **in a given site collection and its subsites**.
Very useful if you receive an error message:
-
+
@@ -16,13 +16,11 @@ when trying to remove a content type.
-
How to use?
+### *How to use?*
+1. Download and install [SharePoint Online SDK](https://www.microsoft.com/en-us/download/details.aspx?id=42038).
-
-1. Download and install SharePoint Online SDK.
-
-2. Download the .ps1 file.
+2. Download the *.ps1* file.
3. Open the file (you can do it also in NotePad)
@@ -39,18 +37,14 @@ $AdminPassword=Read-Host -Prompt "Password" -AsSecureString
$AdminUrl="https://tenant.sharepoint.com/sites/teamsitewithlibraries"
```
-a) Find on your computer where SharePoint.Clitent.dll and SharePoint.Client.Runtime.dll libraries are located and insert the correct paths
-b) Instead of "admin@tenant.onmicrosoft.com" enter you username
-c) Instead of "https://tenant.sharepoint.com/sites/teamsitewithlibraries" enter the name of the site collection where you want to find the content types
-
+a) Find on your computer where SharePoint.Clitent.dll and SharePoint.Client.Runtime.dll libraries are located and insert the correct paths
+b) Instead of "admin@tenant.onmicrosoft.com" enter you username
+c) Instead of "https://tenant.sharepoint.com/sites/teamsitewithlibraries" enter the name of the site collection where you want to find the content types
5. Run the script in Powershell (any module).
6. The result should show the table of names and associated lists and websites where those lists are located
-
-
-
You can also export it to CSV:
@@ -59,4 +53,4 @@ You can also export it to CSV:
-Enjoy and please share feedback!
\ No newline at end of file
+Enjoy and please share feedback!
diff --git a/Content Types/Get/Find content types added to your lists/description.md b/Content Types/Get/Find content types added to your lists/description.md
index b49bed1c..0762a07b 100644
--- a/Content Types/Get/Find content types added to your lists/description.md
+++ b/Content Types/Get/Find content types added to your lists/description.md
@@ -7,16 +7,12 @@ Very useful if you receive an error message:
when trying to remove a content type.
-
-
-
-### How to use?
+### *How to use?*
+1. Download and install [SharePoint Online SDK](https://www.microsoft.com/en-us/download/details.aspx?id=42038).
-1. Download and install SharePoint Online SDK.
-
-2. Download the .ps1 file.
+2. Download the *.ps1* file.
3. Open the file (you can do it also in NotePad)
@@ -35,19 +31,18 @@ $AdminPassword=Read-Host -Prompt "Password" -AsSecureString
$AdminUrl="https://tenant.sharepoint.com/sites/teamsitewithlibraries"
```
-a) Find on your computer where SharePoint.Clitent.dll and SharePoint.Client.Runtime.dll libraries are located and insert the correct paths
-b) Instead of "admin@tenant.onmicrosoft.com" enter you username
-c) Instead of "https://tenant.sharepoint.com/sites/teamsitewithlibraries" enter the name of the site collection where you want to find the content types
+a) Find on your computer where SharePoint.Clitent.dll and SharePoint.Client.Runtime.dll libraries are located and insert the correct paths
+b) Instead of "admin@tenant.onmicrosoft.com" enter you username
+c) Instead of "https://tenant.sharepoint.com/sites/teamsitewithlibraries" enter the name of the site collection where you want to find the content types
-
5. Run the script in Powershell (any module).
6. The result should show the list names in green and connected content types below them
-
+
-Enjoy and please share feedback!
\ No newline at end of file
+Enjoy and please share feedback!
diff --git a/Content Types/Get/Get All Detailed Properties of All Content Types/description.md b/Content Types/Get/Get All Detailed Properties of All Content Types/description.md
index a7ed8f94..f7b48c7d 100644
--- a/Content Types/Get/Get All Detailed Properties of All Content Types/description.md
+++ b/Content Types/Get/Get All Detailed Properties of All Content Types/description.md
@@ -1,33 +1,21 @@
A short script to get all properties of all content types in one SharePoint site collection.
-The script is fully described in an article here:
+The script is fully described in an article [here](http://social.technet.microsoft.com/wiki/contents/articles/31051.sharepoint-online-content-types-in-powershell.aspx).
-http://social.technet.microsoft.com/wiki/contents/articles/31051.sharepoint-online-content-types-in-powershell.aspx
+The script is similar to [Get all properties of all content types in a SharePoint site](https://gallery.technet.microsoft.com/Get-all-properties-of-all-3a9c5c4bhttps://gallery.technet.microsoft.com/Get-all-properties-of-all-3a9c5c4b). In addition to all the default properties it adds also every workflow, field, and fieldLink instance as an additional custom property.
-
-
-The script is similar to Get all properties of all content types in a SharePoint site. In addition to all the default properties it adds also every workflow, field, and fieldLink instance as an additional custom property.
-
-
+### *How to use?*
-How to use?
+1. Download and install [SharePoint Online SDK](https://www.microsoft.com/en-us/download/details.aspx?id=42038).
-
-
-1. Download and install SharePoint Online SDK.
-
-2. Download the .ps1 file.
+2. Download the *.ps1* file.
3. Open the file (you can do it also in NotePad)
4. Insert your data in these lines:
-
-
-
-
```PowerShell
# Paths to SDK. Please verify location on your computer.
Add-Type -Path "c:\Program Files\Common Files\microsoft shared\Web Server Extensions\15\ISAPI\Microsoft.SharePoint.Client.dll"
@@ -38,19 +26,17 @@ $Username="admin@tenant.onmicrosoft.com"
$AdminPassword=Read-Host -Prompt "Password" -AsSecureString
$AdminUrl="https://tenant.sharepoint.com/sites/teamsitewithlibraries"
```
-a) Find on your computer where SharePoint.Clitent.dll and SharePoint.Client.Runtime.dll libraries are located and insert the correct paths
-b) Instead of "admin@tenant.onmicrosoft.com" enter you username
-c) Instead of "https://tenant.sharepoint.com/sites/teamsitewithlibraries" enter the name of the site collection where you want to find the content types
-d) Fill in the properties of the content type.
-
-
-
+a) Find on your computer where SharePoint.Clitent.dll and SharePoint.Client.Runtime.dll libraries are located and insert the correct paths
+b) Instead of "admin@tenant.onmicrosoft.com" enter you username
+c) Instead of "https://tenant.sharepoint.com/sites/teamsitewithlibraries" enter the name of the site collection where you want to find the content types
+d) Fill in the properties of the content type.
5. Run the script in Powershell (any module).
6. Results can be viewed either in Powershell window or exported to csv as a report:
-
+
+
diff --git a/Content Types/Get/Get All Hidden Content Types added to the site/description.md b/Content Types/Get/Get All Hidden Content Types added to the site/description.md
index 1b84d58d..f745aa77 100644
--- a/Content Types/Get/Get All Hidden Content Types added to the site/description.md
+++ b/Content Types/Get/Get All Hidden Content Types added to the site/description.md
@@ -1,4 +1,4 @@
-The script below is described in the article SharePoint Online content types in Powershell: Get and is part of various options on retrieving a single Content Type.
+The script below is described in the article [SharePoint Online content types in Powershell: Get](https://social.technet.microsoft.com/wiki/contents/articles/31151.sharepoint-online-content-types-in-powershell-get.aspx) and is part of various options on retrieving a single Content Type.
@@ -7,9 +7,6 @@ It retrieves the content types that are hidden. If you want to retrieve the cont
```PowerShell
if($cc.Hidden -eq $true)
```
-
-
-
Before running the script, you need to open the file and edit the following lines, entering the Admin username and the site where you want to retrieve the content types. Do not enter the password - you will be prompted for it during the script execution.
diff --git a/Content Types/Get/Get All Properties of All Content Types in All Lists (Detailed) across one site/description.md b/Content Types/Get/Get All Properties of All Content Types in All Lists (Detailed) across one site/description.md
index 1c50c8f9..a6aea7f5 100644
--- a/Content Types/Get/Get All Properties of All Content Types in All Lists (Detailed) across one site/description.md
+++ b/Content Types/Get/Get All Properties of All Content Types in All Lists (Detailed) across one site/description.md
@@ -1,14 +1,8 @@
A short script to get all properties of all content types in all lists across one SharePoint site.
-The script is fully described in an article here:
+The script is fully described in an article [here](http://social.technet.microsoft.com/wiki/contents/articles/31051.sharepoint-online-content-types-in-powershell.aspx).
-http://social.technet.microsoft.com/wiki/contents/articles/31051.sharepoint-online-content-types-in-powershell.aspx
-
-
-
-
-
-The script is similar to Get all properties of all content types in a SharePoint site with the following differences:
+The script is similar to [Get all properties of all content types in a SharePoint site](https://gallery.technet.microsoft.com/Get-all-properties-of-all-3a9c5c4b) with the following differences:
+ In addition to all the default properties it adds also every workflow, field, and fieldLink instance as an additional custom property.
@@ -18,22 +12,16 @@ The script is similar to Get all properties of all content types in a SharePoint
-### How to use?
-
-
+### *How to use?*
-1. Download and install SharePoint Online SDK.
+1. Download and install [SharePoint Online SDK](https://www.microsoft.com/en-us/download/details.aspx?id=42038).
-2. Download the .ps1 file.
+2. Download the *.ps1* file.
3. Open the file (you can do it also in NotePad)
4. Insert your data in these lines:
-
-
-
-
```PowerShell
# Paths to SDK. Please verify location on your computer.
Add-Type -Path "c:\Program Files\Common Files\microsoft shared\Web Server Extensions\15\ISAPI\Microsoft.SharePoint.Client.dll"
@@ -44,18 +32,17 @@ $Username="admin@tenant.onmicrosoft.com"
$AdminPassword=Read-Host -Prompt "Password" -AsSecureString
$AdminUrl="https://tenant.sharepoint.com/sites/teamsitewithlibraries"
```
-a) Find on your computer where SharePoint.Clitent.dll and SharePoint.Client.Runtime.dll libraries are located and insert the correct paths
-b) Instead of "admin@tenant.onmicrosoft.com" enter you username
-c) Instead of "https://tenant.sharepoint.com/sites/teamsitewithlibraries" enter the name of the site collection where you want to find the content types
-d) Fill in the properties of the content type.
-
-
-
+a) Find on your computer where SharePoint.Clitent.dll and SharePoint.Client.Runtime.dll libraries are located and insert the correct paths
+b) Instead of "admin@tenant.onmicrosoft.com" enter you username
+c) Instead of "https://tenant.sharepoint.com/sites/teamsitewithlibraries" enter the name of the site collection where you want to find the content types
+d) Fill in the properties of the content type.
5. Run the script in Powershell (any module).
6. Results can be viewed either in Powershell window or exported to csv as a report:
+
+
diff --git a/Content Types/Get/Get Content Types Derived From One Parent/GetSingleContentTypeLoopParentName.ps1 b/Content Types/Get/Get Content Types Derived From One Parent/GetSingleContentTypeLoopParentName.ps1
index 1a6de352..7a41bd84 100644
--- a/Content Types/Get/Get Content Types Derived From One Parent/GetSingleContentTypeLoopParentName.ps1
+++ b/Content Types/Get/Get Content Types Derived From One Parent/GetSingleContentTypeLoopParentName.ps1
@@ -2,55 +2,38 @@
-function Get-SPOContentType
-{
-
- param (
- [Parameter(Mandatory=$true,Position=1)]
+function Get-SPOContentType{
+ param (
+ [Parameter(Mandatory=$true,Position=1)]
[string]$Username,
[Parameter(Mandatory=$true,Position=2)]
$AdminPassword,
- [Parameter(Mandatory=$true,Position=3)]
+ [Parameter(Mandatory=$true,Position=3)]
[string]$Url,
-[Parameter(Mandatory=$true,Position=4)]
+ [Parameter(Mandatory=$true,Position=4)]
[string]$Parent
- )
-
- $ctx=New-Object Microsoft.SharePoint.Client.ClientContext($Url)
- $ctx.Credentials = New-Object Microsoft.SharePoint.Client.SharePointOnlineCredentials($Username, $AdminPassword)
- $ctx.ExecuteQuery()
-
- $ctx.Load($ctx.Web)
+ )
- $ctx.Load($ctx.Web.ContentTypes)
- $ctx.ExecuteQuery()
+ $ctx=New-Object Microsoft.SharePoint.Client.ClientContext($Url)
+ $ctx.Credentials = New-Object Microsoft.SharePoint.Client.SharePointOnlineCredentials($Username, $AdminPassword)
+ $ctx.ExecuteQuery()
+ $ctx.Load($ctx.Web)
- foreach($cc in $ctx.Web.ContentTypes)
- {
- $ctx.Load($cc.Parent)
- $ctx.ExecuteQuery()
-
+ $ctx.Load($ctx.Web.ContentTypes)
+ $ctx.ExecuteQuery()
- if($cc.Parent.Name.ToString().Trim() -eq $Parent)
- {
- Write-Host $cc.Name
- }
- }
-
-
-
-
-
-
- }
-
-
-
-
-
+ foreach($cc in $ctx.Web.ContentTypes){
+ $ctx.Load($cc.Parent)
+ $ctx.ExecuteQuery()
+ if($cc.Parent.Name.ToString().Trim() -eq $Parent){
+ Write-Host $cc.Name
+ }
+ }
+}
+
# Paths to SDK. Please verify location on your computer.
Add-Type -Path "c:\Program Files\Common Files\microsoft shared\Web Server Extensions\15\ISAPI\Microsoft.SharePoint.Client.dll"
diff --git a/Content Types/Get/Get Content Types Derived From One Parent/description.md b/Content Types/Get/Get Content Types Derived From One Parent/description.md
index c2b1479c..3697ef51 100644
--- a/Content Types/Get/Get Content Types Derived From One Parent/description.md
+++ b/Content Types/Get/Get Content Types Derived From One Parent/description.md
@@ -1,17 +1,9 @@
-The script below is described in the article SharePoint Online content types in Powershell: Get and is part of various options on retrieving a single Content Type.
+The script below is described in the article [SharePoint Online content types in Powershell: Get](https://social.technet.microsoft.com/wiki/contents/articles/31151.sharepoint-online-content-types-in-powershell-get.aspx) and is part of various options on retrieving a single Content Type.
-
-
-It retrieves the content types that derive from specific a specific content type, in the example below it is Audio. In this script the content type is recognized by its ID. If you need a script where the parent content type will be recognized by its name, view this link.
-
-For 50+ other scripts refering to various content type functions, please click View contributions.
-
-
+It retrieves the content types that derive from specific a specific content type, in the example below it is Audio. In this script the content type is recognized by its ID. If you need a script where the parent content type will be recognized by its name, view [this link](https://gallery.technet.microsoft.com/Get-Content-Types-Derived-a0e749de).
-
+For 50+ other scripts refering to various content type functions, please click [View contributions](https://gallery.technet.microsoft.com/site/search?f%5B0%5D.Type=User&f%5B0%5D.Value=Arleta%20Wanat).
-
-
Before running the script, you need to open the file and edit the following lines, entering the Admin username, the site where you want to retrieve the content types, and the id of the content type. Do not enter the password - you will be prompted for it during the script execution.
@@ -32,36 +24,34 @@ $Parent="0x0101009148F5A04DDD49CBA7127AADA5FB792B006973ACD696DC4858A76371B2FB2F4
-For other scripts related to Content Types, you can refer to the article Wiki: SharePoint Online content types in Powershell: Add (en-us)
+For other scripts related to Content Types, you can refer to the article [Wiki: SharePoint Online content types in Powershell: Add (en-us)](https://social.technet.microsoft.com/wiki/contents/articles/31051.sharepoint-online-content-types-in-powershell-add.aspx)
- Adding
-SharePoint Online: Create a content type using Powershell
-Create content type and add directly to SPO list using Powershell
-Create and add content type to a content type hub SharePoint Online
-Create content type and add it to all lists in one site
-Add Content Type to Task Lists
-Add Content Type to Lists with Workflows
-Add existing content type directly to SPO list using Powershell
+*Adding
*
+[SharePoint Online: Create a content type using Powershell](https://gallery.technet.microsoft.com/SharePoint-Online-Create-a-2a4d3057)
+[Create content type and add directly to SPO list using Powershell ](https://gallery.technet.microsoft.com/Create-content-type-and-c5332edb)
+[Create and add content type to a content type hub SharePoint Online ](https://gallery.technet.microsoft.com/Create-and-add-content-f9e8eb6f)
+[Create content type and add it to all lists in one site ](https://gallery.technet.microsoft.com/Create-content-type-and-d41ece6e)
+[Add Content Type to Task Lists ](https://gallery.technet.microsoft.com/Add-Content-Type-to-Task-253d3966)
+[Add Content Type to Lists with Workflows ](https://gallery.technet.microsoft.com/Add-Content-Type-to-Lists-503bd493)
+[Add existing content type directly to SPO list using Powershell ](https://gallery.technet.microsoft.com/Add-existing-content-type-e2cbe9b9)
- Content Type Management
-Allow content type management for all lists in site collection using Powershell
-Allow content type management for all lists in a site using Powershell
-Set content type management setting for SharePoint Online list using Powershell
-Custom Powershell cmdlet Set-SPOList -ContentTypesEnabled
+*Content Type Management
*
+[Allow content type management for all lists in site collection using Powershell ](https://gallery.technet.microsoft.com/Allow-content-type-de3a5a09)
+[Allow content type management for all lists in a site using Powershell ](https://gallery.technet.microsoft.com/Allow-content-type-5bca5157)
+[Set content type management setting for SharePoint Online list using Powershell ](https://gallery.technet.microsoft.com/Set-content-type-39ae4bce)
+[Custom Powershell cmdlet Set-SPOList -ContentTypesEnabled ](https://gallery.technet.microsoft.com/SharePoint-Module-for-5ecbbcf0)
- Related Scripts
-SharePoint Online: Check content types added to your lists
-SharePoint Online: Check content types added to your lists (recursive)
-Get a report on lists where a given content type is added
-SharePoint Online: Remove a content type from all lists in a site collection
+*Related Scripts
*
+[SharePoint Online: Check content types added to your lists ](https://gallery.technet.microsoft.com/SharePoint-Online-Check-052fbdca)
+[SharePoint Online: Check content types added to your lists (recursive) ](https://gallery.technet.microsoft.com/SharePoint-Online-Check-e2650578)
+[Get a report on lists where a given content type is added ](https://gallery.technet.microsoft.com/Get-a-report-on-lists-c2decb62)
+[SharePoint Online: Remove a content type from all lists in a site collection ](https://gallery.technet.microsoft.com/SharePoint-Online-Remove-a-3a19f5b5)
-Get all properties of all content types in a SharePoint site
-Get All Properties of All Content Types (Detailed)
-Get All Properties of All Content Types in All Lists (Detailed) across one site
-Get properties of a single content type by its ID
-
-
+[Get all properties of all content types in a SharePoint site ](https://gallery.technet.microsoft.com/Get-all-properties-of-all-3a9c5c4bhttps://gallery.technet.microsoft.com/Get-all-properties-of-all-3a9c5c4b)
+[Get All Properties of All Content Types (Detailed) ](https://gallery.technet.microsoft.com/Get-All-Properties-of-All-a067d4f2)
+[Get All Properties of All Content Types in All Lists (Detailed) across one site ](https://gallery.technet.microsoft.com/Get-All-Properties-of-All-6e7de504)
+[Get properties of a single content type by its ID ](https://gallery.technet.microsoft.com/Get-properties-of-a-single-eb8020a7)
-Enjoy and please share feedback!
\ No newline at end of file
+Enjoy and please share feedback!
diff --git a/Content Types/Get/Get Content Types with a particular column/description.md b/Content Types/Get/Get Content Types with a particular column/description.md
index 2acec721..e554a086 100644
--- a/Content Types/Get/Get Content Types with a particular column/description.md
+++ b/Content Types/Get/Get Content Types with a particular column/description.md
@@ -1,8 +1,6 @@
-The script below is described in the article SharePoint Online content types in Powershell: Get and is part of various options on retrieving a single Content Type.
+The script below is described in the article [SharePoint Online content types in Powershell: Get](https://social.technet.microsoft.com/wiki/contents/articles/31151.sharepoint-online-content-types-in-powershell-get.aspx) and is part of various options on retrieving a single Content Type.
-
-
-It retrieves content type which have among their columns, one particular column of your choice. In the example below the column is called Copyright.
+It retrieves content type which have among their columns, one particular column of your choice. In the example below the column is called *Copyright*.
@@ -27,54 +25,48 @@ $NameOrTitle="Copyright"
-For 50+ other scripts refering to various content type functions, please click View contributions or refer to the scripts below:
+For 50+ other scripts refering to various content type functions, please click [View contributions](https://gallery.technet.microsoft.com/site/search?f%5B0%5D.Type=User&f%5B0%5D.Value=Arleta%20Wanat) or refer to the scripts below:
-#### Adding
-SharePoint Online: Create a content type using Powershell
-Create content type and add directly to SPO list using Powershell
-Create and add content type to a content type hub SharePoint Online
-Create content type and add it to all lists in one site
-Add Content Type to Task Lists
-Add Content Type to Lists with Workflows
-Add existing content type directly to SPO list using Powershell
-
-#### Getting
-Get all properties of all content types in a SharePoint site
-
-Get All Properties of All Content Types (Detailed)
-Get All Properties of All Content Types in All Lists (Detailed) across one site
-Get properties of a single content type by its ID
-Get content types belonging to a group
-Get All Hidden Content Types added to the site
-Get Single Content Type - Array Method
-Get Names of all content types added to your SPO lists
-Get Names of All Content Types
-Get Names of all Available Content Types
-Get Content Types Derived From One Parent
-Get Content Types Derived From One Parent 2
-
-Get content types which cannot be modified
-
-
-
-#### Content Type Management
-Allow content type management for all lists in site collection using Powershell
-Allow content type management for all lists in a site using Powershell
-Set content type management setting for SharePoint Online list using Powershell
-Custom Powershell cmdlet Set-SPOList -ContentTypesEnabled
-
-
-
-#### Related Scripts
-SharePoint Online: Check content types added to your lists
-SharePoint Online: Check content types added to your lists (recursive)
-Get a report on lists where a given content type is added
-SharePoint Online: Remove a content type from all lists in a site collection
-Compare Web.AvailableContentTypes vs Web.ContentTypes
-
-
+### *Adding*
+[SharePoint Online: Create a content type using Powershell ](https://gallery.technet.microsoft.com/SharePoint-Online-Create-a-2a4d3057)
+[Create content type and add directly to SPO list using Powershell ](https://gallery.technet.microsoft.com/Create-content-type-and-c5332edb)
+[Create and add content type to a content type hub SharePoint Online](https://gallery.technet.microsoft.com/Create-and-add-content-f9e8eb6f)
+[Create content type and add it to all lists in one site ](https://gallery.technet.microsoft.com/Create-content-type-and-d41ece6e)
+[Add Content Type to Task Lists ](https://gallery.technet.microsoft.com/Add-Content-Type-to-Task-253d3966)
+[Add Content Type to Lists with Workflows ](https://gallery.technet.microsoft.com/Add-Content-Type-to-Lists-503bd493)
+[Add existing content type directly to SPO list using Powershell ](https://gallery.technet.microsoft.com/Add-existing-content-type-e2cbe9b9)
+
+### *Getting*
+[Get all properties of all content types in a SharePoint site ](https://gallery.technet.microsoft.com/Get-all-properties-of-all-3a9c5c4b)
+
+[Get All Properties of All Content Types (Detailed) ](https://gallery.technet.microsoft.com/Get-All-Properties-of-All-a067d4f2)
+[Get All Properties of All Content Types in All Lists (Detailed) across one site ](https://gallery.technet.microsoft.com/Get-All-Properties-of-All-6e7de504)
+[Get properties of a single content type by its ID ](https://gallery.technet.microsoft.com/Get-properties-of-a-single-eb8020a7https://gallery.technet.microsoft.com/Get-properties-of-a-single-eb8020a7)
+[Get content types belonging to a group ](https://gallery.technet.microsoft.com/Get-content-types-eb59774a)
+[Get All Hidden Content Types added to the site ](https://gallery.technet.microsoft.com/Get-All-Hidden-Content-83a588a5)
+[Get Single Content Type - Array Method ](https://gallery.technet.microsoft.com/Get-Single-Content-Type-1f79888b)
+[Get Names of all content types added to your SPO lists ](https://gallery.technet.microsoft.com/Get-Names-of-all-content-67a79dac)
+[Get Names of All Content Types ](https://gallery.technet.microsoft.com/Get-Names-of-All-Content-58bfdd29)
+[Get Names of all Available Content Types ](https://gallery.technet.microsoft.com/Get-Names-of-all-Available-ada26a47)
+[Get Content Types Derived From One Parent ](https://gallery.technet.microsoft.com/Get-Content-Types-Derived-b48e7f5f)
+[Get Content Types Derived From One Parent 2](https://gallery.technet.microsoft.com/Get-Content-Types-Derived-a0e749de)
+
+[Get content types which cannot be modified](https://gallery.technet.microsoft.com/Get-content-types-which-029b1968)
+
+### *Content Type Management*
+[Allow content type management for all lists in site collection using Powershell](https://gallery.technet.microsoft.com/Allow-content-type-de3a5a09)
+[Allow content type management for all lists in a site using Powershell](https://gallery.technet.microsoft.com/Allow-content-type-5bca5157)
+[Set content type management setting for SharePoint Online list using Powershell](https://gallery.technet.microsoft.com/Set-content-type-39ae4bce)
+[Custom Powershell cmdlet Set-SPOList -ContentTypesEnabled](https://gallery.technet.microsoft.com/SharePoint-Module-for-5ecbbcf0)
+
+### *Related Scripts*
+[SharePoint Online: Check content types added to your lists](https://gallery.technet.microsoft.com/SharePoint-Online-Check-052fbdca)
+[SharePoint Online: Check content types added to your lists (recursive)](https://gallery.technet.microsoft.com/SharePoint-Online-Check-e2650578)
+[Get a report on lists where a given content type is added](https://gallery.technet.microsoft.com/Get-a-report-on-lists-c2decb62)
+[SharePoint Online: Remove a content type from all lists in a site collection](https://gallery.technet.microsoft.com/SharePoint-Online-Remove-a-3a19f5b5)
+[Compare Web.AvailableContentTypes vs Web.ContentTypes](https://gallery.technet.microsoft.com/Compare-WebAvailableContent-cf03617a)
-Enjoy and please share feedback!
\ No newline at end of file
+Enjoy and please share feedback!
diff --git a/Content Types/Get/Get Names of All Content Types/GetAllContentTypes.ps1 b/Content Types/Get/Get Names of All Content Types/GetAllContentTypes.ps1
index d6a78fc3..543c2e2f 100644
--- a/Content Types/Get/Get Names of All Content Types/GetAllContentTypes.ps1
+++ b/Content Types/Get/Get Names of All Content Types/GetAllContentTypes.ps1
@@ -1,53 +1,30 @@
-function Get-SPOContentType
-{
-
- param (
- [Parameter(Mandatory=$true,Position=1)]
+function Get-SPOContentType{
+ param (
+ [Parameter(Mandatory=$true,Position=1)]
[string]$Username,
[Parameter(Mandatory=$true,Position=2)]
$AdminPassword,
- [Parameter(Mandatory=$true,Position=3)]
+ [Parameter(Mandatory=$true,Position=3)]
[string]$Url
- )
-
- $ctx=New-Object Microsoft.SharePoint.Client.ClientContext($Url)
- $ctx.Credentials = New-Object Microsoft.SharePoint.Client.SharePointOnlineCredentials($Username, $AdminPassword)
- $ctx.ExecuteQuery()
-
- $ctx.Load($ctx.Web)
-
- $ctx.Load($ctx.Web.ContentTypes)
- $ctx.ExecuteQuery()
- Write-Host
- # Write-Host $ctx.Url -BackgroundColor White -ForegroundColor DarkGreen
+ )
- foreach( $cc in $ctx.Web.ContentTypes)
- {
-
- Write-Output $cc.Name
-
- }
-
+ $ctx=New-Object Microsoft.SharePoint.Client.ClientContext($Url)
+ $ctx.Credentials = New-Object Microsoft.SharePoint.Client.SharePointOnlineCredentials($Username, $AdminPassword)
+ $ctx.ExecuteQuery()
+ $ctx.Load($ctx.Web)
-
- }
+ $ctx.Load($ctx.Web.ContentTypes)
+ $ctx.ExecuteQuery()
+ Write-Host
+ # Write-Host $ctx.Url -BackgroundColor White -ForegroundColor DarkGreen
-
-
-
-
-
-
-
-
-
-
-
-
-
+ foreach( $cc in $ctx.Web.ContentTypes){
+ Write-Output $cc.Name
+ }
+}
# Paths to SDK. Please verify location on your computer.
@@ -61,4 +38,4 @@ $AdminUrl="https://tenant.sharepoint.com/sites/teamsitewithlibraries/sub"
-Get-SPOContentType -Username $Username -AdminPassword $AdminPassword -Url $AdminUrl
\ No newline at end of file
+Get-SPOContentType -Username $Username -AdminPassword $AdminPassword -Url $AdminUrl
diff --git a/Content Types/Get/Get Names of All Content Types/description.md b/Content Types/Get/Get Names of All Content Types/description.md
index d9cf120b..dea6fdda 100644
--- a/Content Types/Get/Get Names of All Content Types/description.md
+++ b/Content Types/Get/Get Names of All Content Types/description.md
@@ -6,7 +6,7 @@ The script is part of the explanation on retrieving the content types as describ
-SharePoint Online content types in Powershell: Get
+[SharePoint Online content types in Powershell: Get](https://social.technet.microsoft.com/wiki/contents/articles/31151.sharepoint-online-content-types-in-powershell-get.aspx)
Before running, don't forget to open the file and enter your data:
@@ -26,54 +26,45 @@ $AdminUrl="https://tenant.sharepoint.com/sites/teamsitewithlibraries"
The results can be displayed in the Powershell console:
-
-
-
-
+
or exported to a csv file using Out-File cmdlet:
-
+
-
-
-
-
-For a script that retrieves available content types from a given site (as opposed to content types from a patricular site), please enter here: https://gallery.technet.microsoft.com/Get-Names-of-all-Available-ada26a47
-
-
+For a script that retrieves available content types from a given site (as opposed to content types from a patricular site), please enter [here](https://gallery.technet.microsoft.com/Get-Names-of-all-Available-ada26a47).
-For other scripts related to Content Types, you can refer to the article Wiki: SharePoint Online content types in Powershell: Add (en-us)
+For other scripts related to Content Types, you can refer to the article [Wiki: SharePoint Online content types in Powershell: Add (en-us) ](https://social.technet.microsoft.com/wiki/contents/articles/31051.sharepoint-online-content-types-in-powershell-add.aspx)
- Adding
-SharePoint Online: Create a content type using Powershell
-Create content type and add directly to SPO list using Powershell
-Create and add content type to a content type hub SharePoint Online
-Create content type and add it to all lists in one site
-Add Content Type to Task Lists
-Add Content Type to Lists with Workflows
-Add existing content type directly to SPO list using Powershell
+### *Adding*
+[SharePoint Online: Create a content type using Powershell ](https://gallery.technet.microsoft.com/SharePoint-Online-Create-a-2a4d3057)
+[Create content type and add directly to SPO list using Powershell ](https://gallery.technet.microsoft.com/Create-content-type-and-c5332edb)
+[Create and add content type to a content type hub SharePoint Online ](https://gallery.technet.microsoft.com/Create-and-add-content-f9e8eb6f)
+[Create content type and add it to all lists in one site ](https://gallery.technet.microsoft.com/Create-content-type-and-d41ece6e)
+[Add Content Type to Task Lists ](https://gallery.technet.microsoft.com/Add-Content-Type-to-Task-253d3966)
+[Add Content Type to Lists with Workflows ](https://gallery.technet.microsoft.com/Add-Content-Type-to-Lists-503bd493)
+[Add existing content type directly to SPO list using Powershell ](https://gallery.technet.microsoft.com/Add-existing-content-type-e2cbe9b9)
- Content Type Management
-Allow content type management for all lists in site collection using Powershell
-Allow content type management for all lists in a site using Powershell
-Set content type management setting for SharePoint Online list using Powershell
-Custom Powershell cmdlet Set-SPOList -ContentTypesEnabled
+### *Content Type Management*
+[Allow content type management for all lists in site collection using Powershell ](https://gallery.technet.microsoft.com/Allow-content-type-de3a5a09)
+[Allow content type management for all lists in a site using Powershell ](https://gallery.technet.microsoft.com/Allow-content-type-5bca5157)
+[Set content type management setting for SharePoint Online list using Powershell ](https://gallery.technet.microsoft.com/Set-content-type-39ae4bce)
+[Custom Powershell cmdlet Set-SPOList -ContentTypesEnabled ](https://gallery.technet.microsoft.com/SharePoint-Module-for-5ecbbcf0)
- Related Scripts
-SharePoint Online: Check content types added to your lists
-SharePoint Online: Check content types added to your lists (recursive)
-Get a report on lists where a given content type is added
-SharePoint Online: Remove a content type from all lists in a site collection
+### *Related Scripts*
+[SharePoint Online: Check content types added to your lists ](https://gallery.technet.microsoft.com/SharePoint-Online-Check-052fbdca)
+[SharePoint Online: Check content types added to your lists (recursive) ](https://gallery.technet.microsoft.com/SharePoint-Online-Check-e2650578)
+[Get a report on lists where a given content type is added ](https://gallery.technet.microsoft.com/Get-a-report-on-lists-c2decb62)
+[SharePoint Online: Remove a content type from all lists in a site collection ](https://gallery.technet.microsoft.com/SharePoint-Online-Remove-a-3a19f5b5)
-Get all properties of all content types in a SharePoint site
-Get All Properties of All Content Types (Detailed)
-Get All Properties of All Content Types in All Lists (Detailed) across one site
-Get properties of a single content type by its ID
+[Get all properties of all content types in a SharePoint site ](https://gallery.technet.microsoft.com/Get-all-properties-of-all-3a9c5c4b)
+[Get All Properties of All Content Types (Detailed) ](https://gallery.technet.microsoft.com/Get-All-Properties-of-All-a067d4f2)
+[Get All Properties of All Content Types in All Lists (Detailed) across one site ](https://gallery.technet.microsoft.com/Get-All-Properties-of-All-6e7de504)
+[Get properties of a single content type by its ID ](https://gallery.technet.microsoft.com/Get-properties-of-a-single-eb8020a7)
-Enjoy and please share feedback!
\ No newline at end of file
+Enjoy and please share feedback!
diff --git a/Content Types/Get/Get Names of all Available Content Types/description.md b/Content Types/Get/Get Names of all Available Content Types/description.md
index 68b65331..8bddd15f 100644
--- a/Content Types/Get/Get Names of all Available Content Types/description.md
+++ b/Content Types/Get/Get Names of all Available Content Types/description.md
@@ -6,7 +6,7 @@ The script is part of the explanation on retrieving the content types as describ
-SharePoint Online content types in Powershell: Get
+[SharePoint Online content types in Powershell: Get](social.technet.microsoft.com/wiki/contents/articles/31151.sharepoint-online-content-types-in-powershell-get.aspx)
Before running, don't forget to open the file and enter your data:
@@ -26,52 +26,42 @@ $AdminUrl="https://tenant.sharepoint.com/sites/teamsitewithlibraries/sub"
The results can be displayed in the Powershell console:
-
-
-
-
+
or exported to a csv file using Out-File cmdlet:
-
-
-
-
-
-
-
-For a script that retrieves content types from a given site (as opposed to available content types), please enter here:
-
+
+For a script that retrieves content types from a given site (as opposed to available content types), please enter [here](https://gallery.technet.microsoft.com/Get-Names-of-All-Content-58bfdd29).
-For other scripts related to Content Types, you can refer to the article Wiki: SharePoint Online content types in Powershell: Add (en-us)
-
- Adding
-SharePoint Online: Create a content type using Powershell
-Create content type and add directly to SPO list using Powershell
-Create and add content type to a content type hub SharePoint Online
-Create content type and add it to all lists in one site
-Add Content Type to Task Lists
-Add Content Type to Lists with Workflows
-Add existing content type directly to SPO list using Powershell
-
- Content Type Management
-Allow content type management for all lists in site collection using Powershell
-Allow content type management for all lists in a site using Powershell
-Set content type management setting for SharePoint Online list using Powershell
-Custom Powershell cmdlet Set-SPOList -ContentTypesEnabled
-
- Related Scripts
-SharePoint Online: Check content types added to your lists
-SharePoint Online: Check content types added to your lists (recursive)
-Get a report on lists where a given content type is added
-SharePoint Online: Remove a content type from all lists in a site collection
-
-Get all properties of all content types in a SharePoint site
-Get All Properties of All Content Types (Detailed)
-Get All Properties of All Content Types in All Lists (Detailed) across one site
-Get properties of a single content type by its ID
+For other scripts related to Content Types, you can refer to the article [Wiki: SharePoint Online content types in Powershell: Add (en-us) ](social.technet.microsoft.com/wiki/contents/articles/31051.sharepoint-online-content-types-in-powershell-add.aspx)
+
+### *Adding*
+[SharePoint Online: Create a content type using Powershell ](https://gallery.technet.microsoft.com/SharePoint-Online-Create-a-2a4d3057)
+[Create content type and add directly to SPO list using Powershell ](https://gallery.technet.microsoft.com/Create-content-type-and-c5332edb)
+[Create and add content type to a content type hub SharePoint Online ](https://gallery.technet.microsoft.com/Create-and-add-content-f9e8eb6f)
+[Create content type and add it to all lists in one site ](https://gallery.technet.microsoft.com/Create-content-type-and-d41ece6e)
+[Add Content Type to Task Lists ](https://gallery.technet.microsoft.com/Add-Content-Type-to-Task-253d3966)
+[Add Content Type to Lists with Workflows ](https://gallery.technet.microsoft.com/Add-Content-Type-to-Lists-503bd493)
+[Add existing content type directly to SPO list using Powershell ](https://gallery.technet.microsoft.com/Add-existing-content-type-e2cbe9b9)
+
+### *Content Type Management*
+[Allow content type management for all lists in site collection using Powershell ](https://gallery.technet.microsoft.com/Allow-content-type-de3a5a09)
+[Allow content type management for all lists in a site using Powershell ](https://gallery.technet.microsoft.com/Allow-content-type-5bca5157)
+[Set content type management setting for SharePoint Online list using Powershell ](https://gallery.technet.microsoft.com/Set-content-type-39ae4bce)
+[Custom Powershell cmdlet Set-SPOList -ContentTypesEnabled ](https://gallery.technet.microsoft.com/SharePoint-Module-for-5ecbbcf0)
+
+### *Related Scripts*
+[SharePoint Online: Check content types added to your lists ](https://gallery.technet.microsoft.com/SharePoint-Online-Check-052fbdca)
+[SharePoint Online: Check content types added to your lists (recursive) ](https://gallery.technet.microsoft.com/SharePoint-Online-Check-e2650578)
+[Get a report on lists where a given content type is added ](https://gallery.technet.microsoft.com/Get-a-report-on-lists-c2decb62)
+[SharePoint Online: Remove a content type from all lists in a site collection ](https://gallery.technet.microsoft.com/SharePoint-Online-Remove-a-3a19f5b5)
+
+[Get all properties of all content types in a SharePoint site ](https://gallery.technet.microsoft.com/Get-all-properties-of-all-3a9c5c4b)
+[Get All Properties of All Content Types (Detailed) ](https://gallery.technet.microsoft.com/Get-All-Properties-of-All-a067d4f2)
+[Get All Properties of All Content Types in All Lists (Detailed) across one site ](https://gallery.technet.microsoft.com/Get-All-Properties-of-All-6e7de504)
+[Get properties of a single content type by its ID ](https://gallery.technet.microsoft.com/Get-properties-of-a-single-eb8020a7)
diff --git a/Content Types/Get/Get Names of all content types added to your lists/description.md b/Content Types/Get/Get Names of all content types added to your lists/description.md
index 5e09fe66..c495ab2c 100644
--- a/Content Types/Get/Get Names of all content types added to your lists/description.md
+++ b/Content Types/Get/Get Names of all content types added to your lists/description.md
@@ -3,34 +3,22 @@ A short script to find all content types added to all of your lists in a given s
Very useful if you receive an error message:
-
-
-
-
+
when trying to remove a content type.
-
-
-
-
-
-
-### How to use?
+### *How to use?*
-1. Download and install SharePoint Online SDK.
+1. Download and install [SharePoint Online SDK.](https://www.microsoft.com/en-us/download/details.aspx?id=42038)
-2. Download the .ps1 file.
+2. Download the *.ps1* file.
3. Open the file (you can do it also in NotePad)
4. Insert your data in these lines:
-
-
-
```PowerShell
# Paths to SDK. Please verify location on your computer.
@@ -42,17 +30,15 @@ $Username="admin@tenant.onmicrosoft.com"
$AdminPassword=Read-Host -Prompt "Password" -AsSecureString
$AdminUrl="https://tenant.sharepoint.com/sites/teamsitewithlibraries"
```
-a) Find on your computer where SharePoint.Clitent.dll and SharePoint.Client.Runtime.dll libraries are located and insert the correct paths
-b) Instead of "admin@tenant.onmicrosoft.com" enter you username
-c) Instead of "https://tenant.sharepoint.com/sites/teamsitewithlibraries" enter the name of the site collection where you want to find the content types
-
-
+a) Find on your computer where SharePoint.Clitent.dll and SharePoint.Client.Runtime.dll libraries are located and insert the correct paths
+b) Instead of "admin@tenant.onmicrosoft.com" enter you username
+c) Instead of "https://tenant.sharepoint.com/sites/teamsitewithlibraries" enter the name of the site collection where you want to find the content types
5. Run the script in Powershell (any module).
6. The result should show the list names in green and connected content types below them
-
+
diff --git a/Content Types/Get/Get Single Content Type - Array Method/GetSingleContentType.ps1 b/Content Types/Get/Get Single Content Type - Array Method/GetSingleContentType.ps1
index 583f75bd..83a4b5e0 100644
--- a/Content Types/Get/Get Single Content Type - Array Method/GetSingleContentType.ps1
+++ b/Content Types/Get/Get Single Content Type - Array Method/GetSingleContentType.ps1
@@ -1,26 +1,22 @@
-function Get-SPOContentType
-{
-
- param (
- [Parameter(Mandatory=$true,Position=1)]
+function Get-SPOContentType{
+ param (
+ [Parameter(Mandatory=$true,Position=1)]
[string]$Username,
[Parameter(Mandatory=$true,Position=2)]
$AdminPassword,
- [Parameter(Mandatory=$true,Position=3)]
+ [Parameter(Mandatory=$true,Position=3)]
[string]$Url
- )
-
- $ctx=New-Object Microsoft.SharePoint.Client.ClientContext($Url)
- $ctx.Credentials = New-Object Microsoft.SharePoint.Client.SharePointOnlineCredentials($Username, $AdminPassword)
- $ctx.ExecuteQuery()
-
- $ctx.Load($ctx.Web)
-
- $ctx.Load($ctx.Web.ContentTypes)
- $ctx.ExecuteQuery()
- Write-Host $ctx.Web.ContentTypes[0].Name
-
- }
+ )
+
+ $ctx=New-Object Microsoft.SharePoint.Client.ClientContext($Url)
+ $ctx.Credentials = New-Object Microsoft.SharePoint.Client.SharePointOnlineCredentials($Username, $AdminPassword)
+ $ctx.ExecuteQuery()
+
+ $ctx.Load($ctx.Web)
+ $ctx.Load($ctx.Web.ContentTypes)
+ $ctx.ExecuteQuery()
+ Write-Host $ctx.Web.ContentTypes[0].Name
+}
diff --git a/Content Types/Get/Get Single Content Type - Array Method/description.md b/Content Types/Get/Get Single Content Type - Array Method/description.md
index bc9499eb..d667d5c1 100644
--- a/Content Types/Get/Get Single Content Type - Array Method/description.md
+++ b/Content Types/Get/Get Single Content Type - Array Method/description.md
@@ -1,4 +1,4 @@
-The script below is described in the article SharePoint Online content types in Powershell: Get and is part of various options on retrieving a single Content Type.
+The script below is described in the article [SharePoint Online content types in Powershell: Get](https://social.technet.microsoft.com/wiki/contents/articles/31151.sharepoint-online-content-types-in-powershell-get.aspx) and is part of various options on retrieving a single Content Type.
@@ -21,39 +21,39 @@ $Username="admin@tenant.onmicrosoft.com"
$AdminPassword=Read-Host -Prompt "Password" -AsSecureString
$AdminUrl="https://tenant.sharepoint.com/sites/teamsitewithlibraries"
```
-If you have any questions, please use Q&A section
+**If you have any questions, please open an issue!**
-For other scripts related to Content Types, you can refer to the article Wiki: SharePoint Online content types in Powershell: Add (en-us)
-
-## Adding
-SharePoint Online: Create a content type using Powershell
-Create content type and add directly to SPO list using Powershell
-Create and add content type to a content type hub SharePoint Online
-Create content type and add it to all lists in one site
-Add Content Type to Task Lists
-Add Content Type to Lists with Workflows
-Add existing content type directly to SPO list using Powershell
-
-## Content Type Management
-Allow content type management for all lists in site collection using Powershell
-Allow content type management for all lists in a site using Powershell
-Set content type management setting for SharePoint Online list using Powershell
-Custom Powershell cmdlet Set-SPOList -ContentTypesEnabled
-
-## Related Scripts
-SharePoint Online: Check content types added to your lists
-SharePoint Online: Check content types added to your lists (recursive)
-Get a report on lists where a given content type is added
-SharePoint Online: Remove a content type from all lists in a site collection
-
-Get all properties of all content types in a SharePoint site
-Get All Properties of All Content Types (Detailed)
-Get All Properties of All Content Types in All Lists (Detailed) across one site
-Get properties of a single content type by its ID
+For other scripts related to Content Types, you can refer to the article [Wiki: SharePoint Online content types in Powershell: Add (en-us) ](https://social.technet.microsoft.com/wiki/contents/articles/31151.sharepoint-online-content-types-in-powershell-get.aspx)
+
+### *Adding*
+[SharePoint Online: Create a content type using Powershell ](https://gallery.technet.microsoft.com/SharePoint-Online-Create-a-2a4d3057)
+[Create content type and add directly to SPO list using Powershell ](https://gallery.technet.microsoft.com/Create-content-type-and-c5332edb)
+[Create and add content type to a content type hub SharePoint Online ](https://gallery.technet.microsoft.com/Create-and-add-content-f9e8eb6f)
+[Create content type and add it to all lists in one site ](https://gallery.technet.microsoft.com/Create-content-type-and-d41ece6e)
+[Add Content Type to Task Lists ](https://gallery.technet.microsoft.com/Add-Content-Type-to-Task-253d3966)
+[Add Content Type to Lists with Workflows ](https://gallery.technet.microsoft.com/Add-Content-Type-to-Lists-503bd493)
+[Add existing content type directly to SPO list using Powershell ](https://gallery.technet.microsoft.com/Add-existing-content-type-e2cbe9b9)
+
+### *Content Type Management*
+[Allow content type management for all lists in site collection using Powershell ](https://gallery.technet.microsoft.com/Allow-content-type-de3a5a09)
+[Allow content type management for all lists in a site using Powershell ](https://gallery.technet.microsoft.com/Allow-content-type-5bca5157)
+[Set content type management setting for SharePoint Online list using Powershell ](https://gallery.technet.microsoft.com/Set-content-type-39ae4bce)
+[Custom Powershell cmdlet Set-SPOList -ContentTypesEnabled ](https://gallery.technet.microsoft.com/SharePoint-Module-for-5ecbbcf0)
+
+### *Related Scripts*
+[SharePoint Online: Check content types added to your lists ](https://gallery.technet.microsoft.com/SharePoint-Online-Check-052fbdca)
+[SharePoint Online: Check content types added to your lists (recursive) ](https://gallery.technet.microsoft.com/SharePoint-Online-Check-e2650578)
+[Get a report on lists where a given content type is added ](https://gallery.technet.microsoft.com/Get-a-report-on-lists-c2decb62)
+[SharePoint Online: Remove a content type from all lists in a site collection ](https://gallery.technet.microsoft.com/SharePoint-Online-Remove-a-3a19f5b5)
+
+[Get all properties of all content types in a SharePoint site ](https://gallery.technet.microsoft.com/Get-all-properties-of-all-3a9c5c4b)
+[Get All Properties of All Content Types (Detailed) ](https://gallery.technet.microsoft.com/Get-All-Properties-of-All-a067d4f2)
+[Get All Properties of All Content Types in All Lists (Detailed) across one site ](https://gallery.technet.microsoft.com/Get-All-Properties-of-All-6e7de504)
+[Get properties of a single content type by its ID ](https://gallery.technet.microsoft.com/Get-properties-of-a-single-eb8020a7)
Enjoy and please share feedback!
diff --git a/Content Types/Get/Get all properties of all content types in a site/ContentTypesWithoutPSObjectWithoutEXtraProperties.ps1 b/Content Types/Get/Get all properties of all content types in a site/ContentTypesWithoutPSObjectWithoutEXtraProperties.ps1
index 07b6b94c..f13db586 100644
--- a/Content Types/Get/Get all properties of all content types in a site/ContentTypesWithoutPSObjectWithoutEXtraProperties.ps1
+++ b/Content Types/Get/Get all properties of all content types in a site/ContentTypesWithoutPSObjectWithoutEXtraProperties.ps1
@@ -1,59 +1,35 @@
-function Get-SPOContentType
-{
-
- param (
- [Parameter(Mandatory=$true,Position=1)]
+function Get-SPOContentType{
+ param (
+ [Parameter(Mandatory=$true,Position=1)]
[string]$Username,
[Parameter(Mandatory=$true,Position=2)]
$AdminPassword,
- [Parameter(Mandatory=$true,Position=3)]
+ [Parameter(Mandatory=$true,Position=3)]
[string]$Url
- )
-
- $ctx=New-Object Microsoft.SharePoint.Client.ClientContext($Url)
- $ctx.Credentials = New-Object Microsoft.SharePoint.Client.SharePointOnlineCredentials($Username, $AdminPassword)
- $ctx.ExecuteQuery()
-
- $ctx.Load($ctx.Web)
- $ctx.Load($ctx.Web.ContentTypes)
- $ctx.ExecuteQuery()
- Write-Host
- Write-Host $ctx.Url -BackgroundColor White -ForegroundColor DarkGreen
- foreach( $cc in $ctx.Web.ContentTypes)
- {
-
-
- $ctx.Load($cc)
- $ctx.Load($cc.FieldLinks)
- $ctx.Load($cc.Fields)
- $ctx.Load($cc.WorkflowAssociations)
- $ctx.ExecuteQuery()
-
- Write-Output $cc
- }
+ )
-
-
+ $ctx=New-Object Microsoft.SharePoint.Client.ClientContext($Url)
+ $ctx.Credentials = New-Object Microsoft.SharePoint.Client.SharePointOnlineCredentials($Username, $AdminPassword)
+ $ctx.ExecuteQuery()
-
-
- }
+ $ctx.Load($ctx.Web)
+ $ctx.Load($ctx.Web.ContentTypes)
+ $ctx.ExecuteQuery()
+ Write-Host
+ Write-Host $ctx.Url -BackgroundColor White -ForegroundColor DarkGreen
+ foreach( $cc in $ctx.Web.ContentTypes){
+ $ctx.Load($cc)
+ $ctx.Load($cc.FieldLinks)
+ $ctx.Load($cc.Fields)
+ $ctx.Load($cc.WorkflowAssociations)
+ $ctx.ExecuteQuery()
-
-
-
-
-
-
-
-
-
-
-
-
+ Write-Output $cc
+ }
+}
# Paths to SDK. Please verify location on your computer.
@@ -67,4 +43,4 @@ $AdminUrl="https://tenant.sharepoint.com/sites/teamsitewithlibraries"
-Get-SPOContentType -Username $Username -AdminPassword $AdminPassword -Url $AdminUrl
\ No newline at end of file
+Get-SPOContentType -Username $Username -AdminPassword $AdminPassword -Url $AdminUrl
diff --git a/Content Types/Get/Get all properties of all content types in a site/description.md b/Content Types/Get/Get all properties of all content types in a site/description.md
index b99e770e..aa9e5854 100644
--- a/Content Types/Get/Get all properties of all content types in a site/description.md
+++ b/Content Types/Get/Get all properties of all content types in a site/description.md
@@ -1,24 +1,12 @@
A short script to get all properties of all content types in one SharePoint site collection.
-The script is fully described in an article here:
+The script is fully described in an article [here](http://social.technet.microsoft.com/wiki/contents/articles/31051.sharepoint-online-content-types-in-powershell.aspx).
-http://social.technet.microsoft.com/wiki/contents/articles/31051.sharepoint-online-content-types-in-powershell.aspx
+### *How to use?*
-
-
-
-
-
-
-
-
-### How to use?
+1. Download and install [SharePoint Online SDK](https://www.microsoft.com/en-us/download/details.aspx?id=42038).
-
-
-1. Download and install SharePoint Online SDK.
-
-2. Download the .ps1 file.
+2. Download the *.ps1* file.
3. Open the file (you can do it also in NotePad)
@@ -38,19 +26,17 @@ $Username="admin@tenant.onmicrosoft.com"
$AdminPassword=Read-Host -Prompt "Password" -AsSecureString
$AdminUrl="https://tenant.sharepoint.com/sites/teamsitewithlibraries"
```
-a) Find on your computer where SharePoint.Clitent.dll and SharePoint.Client.Runtime.dll libraries are located and insert the correct paths
-b) Instead of "admin@tenant.onmicrosoft.com" enter you username
-c) Instead of "https://tenant.sharepoint.com/sites/teamsitewithlibraries" enter the name of the site collection where you want to find the content types
-d) Fill in the properties of the content type.
-
-
-
+a) Find on your computer where SharePoint.Clitent.dll and SharePoint.Client.Runtime.dll libraries are located and insert the correct paths
+b) Instead of "admin@tenant.onmicrosoft.com" enter you username
+c) Instead of "https://tenant.sharepoint.com/sites/teamsitewithlibraries" enter the name of the site collection where you want to find the content types
+d) Fill in the properties of the content type.
5. Run the script in Powershell (any module).
6. Results can be viewed either in Powershell window or exported to csv as a report:
-
+
+
diff --git a/Content Types/Get/Get content types belonging to a group/GetSingleContentTypeLoopGroup.ps1 b/Content Types/Get/Get content types belonging to a group/GetSingleContentTypeLoopGroup.ps1
index cce6abe6..858b76fe 100644
--- a/Content Types/Get/Get content types belonging to a group/GetSingleContentTypeLoopGroup.ps1
+++ b/Content Types/Get/Get content types belonging to a group/GetSingleContentTypeLoopGroup.ps1
@@ -1,49 +1,33 @@
-function Get-SPOContentType
-{
-
- param (
- [Parameter(Mandatory=$true,Position=1)]
+function Get-SPOContentType{
+ param (
+ [Parameter(Mandatory=$true,Position=1)]
[string]$Username,
[Parameter(Mandatory=$true,Position=2)]
$AdminPassword,
- [Parameter(Mandatory=$true,Position=3)]
+ [Parameter(Mandatory=$true,Position=3)]
[string]$Url,
-[Parameter(Mandatory=$true,Position=4)]
+ [Parameter(Mandatory=$true,Position=4)]
[string]$GroupName
- )
-
- $ctx=New-Object Microsoft.SharePoint.Client.ClientContext($Url)
- $ctx.Credentials = New-Object Microsoft.SharePoint.Client.SharePointOnlineCredentials($Username, $AdminPassword)
- $ctx.ExecuteQuery()
-
- $ctx.Load($ctx.Web)
-
- $ctx.Load($ctx.Web.ContentTypes)
- $ctx.ExecuteQuery()
-
-
- foreach($cc in $ctx.Web.ContentTypes)
- {
- if($cc.Group -eq $GroupName)
- {
- Write-Host $cc.Name
- }
- }
-
-
-
-
-
-
-
- }
-
-
-
-
-
+ )
+
+ $ctx=New-Object Microsoft.SharePoint.Client.ClientContext($Url)
+ $ctx.Credentials = New-Object Microsoft.SharePoint.Client.SharePointOnlineCredentials($Username, $AdminPassword)
+ $ctx.ExecuteQuery()
+
+ $ctx.Load($ctx.Web)
+
+ $ctx.Load($ctx.Web.ContentTypes)
+ $ctx.ExecuteQuery()
+
+
+ foreach($cc in $ctx.Web.ContentTypes){
+ if($cc.Group -eq $GroupName){
+ Write-Host $cc.Name
+ }
+ }
+}
# Paths to SDK. Please verify location on your computer.
@@ -58,4 +42,4 @@ $GroupName="Business Intelligence"
-Get-SPOContentType -Username $Username -AdminPassword $AdminPassword -Url $AdminUrl -GroupName $GroupName
\ No newline at end of file
+Get-SPOContentType -Username $Username -AdminPassword $AdminPassword -Url $AdminUrl -GroupName $GroupName
diff --git a/Content Types/Get/Get content types belonging to a group/description.md b/Content Types/Get/Get content types belonging to a group/description.md
index bd8dc86b..33db0efb 100644
--- a/Content Types/Get/Get content types belonging to a group/description.md
+++ b/Content Types/Get/Get content types belonging to a group/description.md
@@ -1,4 +1,4 @@
-The script below is described in the article SharePoint Online content types in Powershell: Get and is part of various options on retrieving a single Content Type.
+The script below is described in the article [SharePoint Online content types in Powershell: Get](https://social.technet.microsoft.com/wiki/contents/articles/31151.sharepoint-online-content-types-in-powershell-get.aspx) and is part of various options on retrieving a single Content Type.
diff --git a/Content Types/Get/Get content types which cannot be modified/GetSingleContentTypeLoopSealed.ps1 b/Content Types/Get/Get content types which cannot be modified/GetSingleContentTypeLoopSealed.ps1
index eb3ead2e..204da42b 100644
--- a/Content Types/Get/Get content types which cannot be modified/GetSingleContentTypeLoopSealed.ps1
+++ b/Content Types/Get/Get content types which cannot be modified/GetSingleContentTypeLoopSealed.ps1
@@ -2,51 +2,32 @@
-function Get-SPOContentType
-{
-
- param (
- [Parameter(Mandatory=$true,Position=1)]
+function Get-SPOContentType{
+ param (
+ [Parameter(Mandatory=$true,Position=1)]
[string]$Username,
[Parameter(Mandatory=$true,Position=2)]
$AdminPassword,
- [Parameter(Mandatory=$true,Position=3)]
+ [Parameter(Mandatory=$true,Position=3)]
[string]$Url
- )
-
- $ctx=New-Object Microsoft.SharePoint.Client.ClientContext($Url)
- $ctx.Credentials = New-Object Microsoft.SharePoint.Client.SharePointOnlineCredentials($Username, $AdminPassword)
- $ctx.ExecuteQuery()
-
- $ctx.Load($ctx.Web)
+ )
- $ctx.Load($ctx.Web.ContentTypes)
- $ctx.ExecuteQuery()
+ $ctx=New-Object Microsoft.SharePoint.Client.ClientContext($Url)
+ $ctx.Credentials = New-Object Microsoft.SharePoint.Client.SharePointOnlineCredentials($Username, $AdminPassword)
+ $ctx.ExecuteQuery()
+ $ctx.Load($ctx.Web)
- foreach($cc in $ctx.Web.ContentTypes)
- {
-
-
+ $ctx.Load($ctx.Web.ContentTypes)
+ $ctx.ExecuteQuery()
- if($cc.Sealed -eq $true)
- {
- Write-Host $cc.Name
- }
- }
-
-
-
-
-
-
- }
-
-
-
-
-
+ foreach($cc in $ctx.Web.ContentTypes){
+ if($cc.Sealed -eq $true){
+ Write-Host $cc.Name
+ }
+ }
+}
# Paths to SDK. Please verify location on your computer.
diff --git a/Content Types/Get/Get content types which cannot be modified/description.md b/Content Types/Get/Get content types which cannot be modified/description.md
index c5f2a648..25bd2b2c 100644
--- a/Content Types/Get/Get content types which cannot be modified/description.md
+++ b/Content Types/Get/Get content types which cannot be modified/description.md
@@ -4,14 +4,7 @@ The script below is described in the article SharePoint Online content types in
It retrieves the content types which cannot be modified. It uses the .Sealed property of a content type:
-Sealed Gets or sets whether the content type can be modified.
-
-
-
-
-
-
-
+[Sealed](https://docs.microsoft.com/en-us/previous-versions/office/sharepoint-server/jj168043(v=office.15)?redirectedfrom=MSDN) *Gets or sets whether the content type can be modified.*
Before running the script, you need to open the file and edit the following lines, entering the Admin username, the site where you want to retrieve the content types, and the id of the content type. Do not enter the password - you will be prompted for it during the script execution.
@@ -29,52 +22,52 @@ $AdminUrl="https://tenant.sharepoint.com/sites/powie1"
-For 50+ other scripts refering to various content type functions, please click View contributions or refer to the scripts below:
+For 50+ other scripts refering to various content type functions, please click [View contributions](https://gallery.technet.microsoft.com/site/search?f%5B0%5D.Type=User&f%5B0%5D.Value=Arleta%20Wanat) or refer to the scripts below:
-#### Adding
-SharePoint Online: Create a content type using Powershell
-Create content type and add directly to SPO list using Powershell
-Create and add content type to a content type hub SharePoint Online
-Create content type and add it to all lists in one site
-Add Content Type to Task Lists
-Add Content Type to Lists with Workflows
-Add existing content type directly to SPO list using Powershell
+### *Adding*
+[SharePoint Online: Create a content type using Powershell ](https://gallery.technet.microsoft.com/SharePoint-Online-Create-a-2a4d3057)
+[Create content type and add directly to SPO list using Powershell ](https://gallery.technet.microsoft.com/Create-content-type-and-c5332edb)
+[Create and add content type to a content type hub SharePoint Online](https://gallery.technet.microsoft.com/Create-and-add-content-f9e8eb6f)
+[Create content type and add it to all lists in one site ](https://gallery.technet.microsoft.com/Create-content-type-and-d41ece6e)
+[Add Content Type to Task Lists ](https://gallery.technet.microsoft.com/Add-Content-Type-to-Task-253d3966)
+[Add Content Type to Lists with Workflows ](https://gallery.technet.microsoft.com/Add-Content-Type-to-Lists-503bd493)
+[Add existing content type directly to SPO list using Powershell ](https://gallery.technet.microsoft.com/Add-existing-content-type-e2cbe9b9)
-#### Getting
-Get all properties of all content types in a SharePoint site
+### *Getting*
+[Get all properties of all content types in a SharePoint site ](https://gallery.technet.microsoft.com/Get-all-properties-of-all-3a9c5c4b)
-Get All Properties of All Content Types (Detailed)
-Get All Properties of All Content Types in All Lists (Detailed) across one site
-Get properties of a single content type by its ID
-Get content types belonging to a group
-Get All Hidden Content Types added to the site
-Get Single Content Type - Array Method
-Get Names of all content types added to your SPO lists
-Get Names of All Content Types
-Get Names of all Available Content Types
-Get Content Types Derived From One Parent
-Get Content Types Derived From One Parent 2
+[Get All Properties of All Content Types (Detailed) ](https://gallery.technet.microsoft.com/Get-All-Properties-of-All-a067d4f2)
+[Get All Properties of All Content Types in All Lists (Detailed) across one site ](https://gallery.technet.microsoft.com/Get-All-Properties-of-All-6e7de504)
+[Get properties of a single content type by its ID ](https://gallery.technet.microsoft.com/Get-properties-of-a-single-eb8020a7)
+[Get content types belonging to a group ](https://gallery.technet.microsoft.com/Get-content-types-eb59774a)
+[Get All Hidden Content Types added to the site ](https://gallery.technet.microsoft.com/Get-All-Hidden-Content-83a588a5)
+[Get Single Content Type - Array Method ](https://gallery.technet.microsoft.com/Get-Single-Content-Type-1f79888b)
+[Get Names of all content types added to your SPO lists ](https://gallery.technet.microsoft.com/Get-Names-of-all-content-67a79dac)
+[Get Names of All Content Types ](https://gallery.technet.microsoft.com/Get-Names-of-All-Content-58bfdd29)
+[Get Names of all Available Content Types ](https://gallery.technet.microsoft.com/Get-Names-of-all-Available-ada26a47)
+[Get Content Types Derived From One Parent ](https://gallery.technet.microsoft.com/Get-Content-Types-Derived-b48e7f5f)
+[Get Content Types Derived From One Parent 2](https://gallery.technet.microsoft.com/Get-Content-Types-Derived-a0e749de)
-#### Content Type Management
-Allow content type management for all lists in site collection using Powershell
-Allow content type management for all lists in a site using Powershell
-Set content type management setting for SharePoint Online list using Powershell
-Custom Powershell cmdlet Set-SPOList -ContentTypesEnabled
+### *Content Type Management*
+[Allow content type management for all lists in site collection using Powershell](https://gallery.technet.microsoft.com/Allow-content-type-de3a5a09)
+[Allow content type management for all lists in a site using Powershell](https://gallery.technet.microsoft.com/Allow-content-type-5bca5157)
+[Set content type management setting for SharePoint Online list using Powershell](https://gallery.technet.microsoft.com/Set-content-type-39ae4bce)
+[Custom Powershell cmdlet Set-SPOList -ContentTypesEnabled](https://gallery.technet.microsoft.com/SharePoint-Module-for-5ecbbcf0)
-#### Related Scripts
-SharePoint Online: Check content types added to your lists
-SharePoint Online: Check content types added to your lists (recursive)
-Get a report on lists where a given content type is added
-SharePoint Online: Remove a content type from all lists in a site collection
-Compare Web.AvailableContentTypes vs Web.ContentTypes
+### *Related Scripts*
+[SharePoint Online: Check content types added to your lists](https://gallery.technet.microsoft.com/SharePoint-Online-Check-052fbdca)
+[SharePoint Online: Check content types added to your lists (recursive)](https://gallery.technet.microsoft.com/SharePoint-Online-Check-e2650578)
+[Get a report on lists where a given content type is added](https://gallery.technet.microsoft.com/Get-a-report-on-lists-c2decb62)
+[SharePoint Online: Remove a content type from all lists in a site collection](https://gallery.technet.microsoft.com/SharePoint-Online-Remove-a-3a19f5b5)
+[Compare Web.AvailableContentTypes vs Web.ContentTypes](https://gallery.technet.microsoft.com/Compare-WebAvailableContent-cf03617a)
-Enjoy and please share feedback!
\ No newline at end of file
+Enjoy and please share feedback!
diff --git a/Content Types/Get/Get properties of a single content type by its ID/GetContentTypePropertiesByID.ps1 b/Content Types/Get/Get properties of a single content type by its ID/GetContentTypePropertiesByID.ps1
index 51bc36f0..fdfaefe2 100644
--- a/Content Types/Get/Get properties of a single content type by its ID/GetContentTypePropertiesByID.ps1
+++ b/Content Types/Get/Get properties of a single content type by its ID/GetContentTypePropertiesByID.ps1
@@ -1,54 +1,46 @@
-function Get-SPOContentType
-{
-
- param (
- [Parameter(Mandatory=$true,Position=1)]
+function Get-SPOContentType{
+ param (
+ [Parameter(Mandatory=$true,Position=1)]
[string]$Username,
[Parameter(Mandatory=$true,Position=2)]
$AdminPassword,
- [Parameter(Mandatory=$true,Position=3)]
+ [Parameter(Mandatory=$true,Position=3)]
[string]$Url,
-[Parameter(Mandatory=$true,Position=4)]
+ [Parameter(Mandatory=$true,Position=4)]
[string]$CTID
- )
-
- $ctx=New-Object Microsoft.SharePoint.Client.ClientContext($Url)
- $ctx.Credentials = New-Object Microsoft.SharePoint.Client.SharePointOnlineCredentials($Username, $AdminPassword)
- $ctx.ExecuteQuery()
-
- $ctx.Load($ctx.Web)
- $cc=$ctx.Web.ContentTypes.GetById($CTID)
- $ctx.Load($cc)
- $ctx.ExecuteQuery()
-
- $ctx.Load($cc.FieldLinks)
- $ctx.Load($cc.Fields)
- $ctx.Load($cc.WorkflowAssociations)
- $ctx.ExecuteQuery()
- $cc | Add-Member NoteProperty Web($url)
- foreach($field in $cc.Fields)
- {
- $PropertyName="Field"+$field.ID
- $cc | Add-Member NoteProperty $PropertyName($field.Title)
- }
- foreach($fieldlink in $cc.FieldLinks)
- {
- $PropertyName="Fieldlink"+$fieldlink.ID
- $cc | Add-Member NoteProperty $PropertyName($fieldlink.Name)
- }
- foreach($workflow in $cc.WorkflowAssociations)
- {
- $PropertyName="Workflow"+$workflow.ID
- $cc | Add-Member NoteProperty $PropertyName($workflow.Name)
- }
- Write-Output $cc
-
- }
-
+ )
-
-
-
+ $ctx=New-Object Microsoft.SharePoint.Client.ClientContext($Url)
+ $ctx.Credentials = New-Object Microsoft.SharePoint.Client.SharePointOnlineCredentials($Username, $AdminPassword)
+ $ctx.ExecuteQuery()
+
+ $ctx.Load($ctx.Web)
+ $cc=$ctx.Web.ContentTypes.GetById($CTID)
+ $ctx.Load($cc)
+ $ctx.ExecuteQuery()
+
+ $ctx.Load($cc.FieldLinks)
+ $ctx.Load($cc.Fields)
+ $ctx.Load($cc.WorkflowAssociations)
+ $ctx.ExecuteQuery()
+ $cc | Add-Member NoteProperty Web($url)
+
+ foreach($field in $cc.Fields){
+ $PropertyName="Field"+$field.ID
+ $cc | Add-Member NoteProperty $PropertyName($field.Title)
+ }
+
+ foreach($fieldlink in $cc.FieldLinks){
+ $PropertyName="Fieldlink"+$fieldlink.ID
+ $cc | Add-Member NoteProperty $PropertyName($fieldlink.Name)
+ }
+
+ foreach($workflow in $cc.WorkflowAssociations){
+ $PropertyName="Workflow"+$workflow.ID
+ $cc | Add-Member NoteProperty $PropertyName($workflow.Name)
+ }
+ Write-Output $cc
+}
# Paths to SDK. Please verify location on your computer.
diff --git a/Content Types/Get/Get properties of a single content type by its ID/description.md b/Content Types/Get/Get properties of a single content type by its ID/description.md
index f8b8ce0b..4dffa6aa 100644
--- a/Content Types/Get/Get properties of a single content type by its ID/description.md
+++ b/Content Types/Get/Get properties of a single content type by its ID/description.md
@@ -1,14 +1,9 @@
A short script to get all properties of a single content type identified by its ID
-The script is fully described in an article here:
-
-http://social.technet.microsoft.com/wiki/contents/articles/31051.sharepoint-online-content-types-in-powershell.aspx
-
+The script is fully described in an article [here](http://social.technet.microsoft.com/wiki/contents/articles/31051.sharepoint-online-content-types-in-powershell.aspx).
-
-
-The script is similar to Get all properties of all content types in a SharePoint site with the following differences:
+The script is similar to [Get all properties of all content types in a SharePoint site](https://gallery.technet.microsoft.com/Get-all-properties-of-all-3a9c5c4b) with the following differences:
+ In addition to all the default properties it adds also every workflow, field, and fieldLink instance as an additional custom property.
@@ -18,13 +13,11 @@ The script is similar to Get all properties of all content types in a SharePoint
-How to use?
-
+*How to use?
*
+1. Download and install [SharePoint Online SDK](https://www.microsoft.com/en-us/download/details.aspx?id=42038).
-1. Download and install SharePoint Online SDK.
-
-2. Download the .ps1 file.
+2. Download the *.ps1* file.
3. Open the file (you can do it also in NotePad)
@@ -46,13 +39,10 @@ $AdminUrl="https://tenant.sharepoint.com/sites/teamsitewithlibraries"
$CTID="0x00A7470EADF4194E2E9ED1031B61DA0884"
```
-a) Find on your computer where SharePoint.Clitent.dll and SharePoint.Client.Runtime.dll libraries are located and insert the correct paths
-b) Instead of "admin@tenant.onmicrosoft.com" enter you username
-c) Instead of "https://tenant.sharepoint.com/sites/teamsitewithlibraries" enter the name of the site collection where you want to find the content types
-d) Fill in the ID of the content type ($CTID)
-
-
-
+a) Find on your computer where SharePoint.Clitent.dll and SharePoint.Client.Runtime.dll libraries are located and insert the correct paths
+b) Instead of "admin@tenant.onmicrosoft.com" enter you username
+c) Instead of "https://tenant.sharepoint.com/sites/teamsitewithlibraries" enter the name of the site collection where you want to find the content types
+d) Fill in the ID of the content type ($CTID)
5. Run the script in Powershell (any module).
diff --git a/Content Types/Get/Lists where a given content type is added/RecursiveContentTypesName.ps1 b/Content Types/Get/Lists where a given content type is added/RecursiveContentTypesName.ps1
index cca809cd..70e3a2b5 100644
--- a/Content Types/Get/Lists where a given content type is added/RecursiveContentTypesName.ps1
+++ b/Content Types/Get/Lists where a given content type is added/RecursiveContentTypesName.ps1
@@ -1,73 +1,51 @@
-function Get-SPOContentType
-{
-
- param (
- [Parameter(Mandatory=$true,Position=1)]
+function Get-SPOContentType{
+ param (
+ [Parameter(Mandatory=$true,Position=1)]
[string]$Username,
[Parameter(Mandatory=$true,Position=2)]
$AdminPassword,
- [Parameter(Mandatory=$true,Position=3)]
+ [Parameter(Mandatory=$true,Position=3)]
[string]$Url,
- [Parameter(Mandatory=$true,Position=4)]
+ [Parameter(Mandatory=$true,Position=4)]
[string]$ContentTypeName
- )
-
- $ctx=New-Object Microsoft.SharePoint.Client.ClientContext($Url)
- $ctx.Credentials = New-Object Microsoft.SharePoint.Client.SharePointOnlineCredentials($Username, $AdminPassword)
- $ctx.ExecuteQuery()
-
- $ctx.Load($ctx.Web.Lists)
- $ctx.Load($ctx.Web.Webs)
- $ctx.ExecuteQuery()
- Write-Host
- Write-Host $ctx.Url -BackgroundColor White -ForegroundColor DarkGreen
- foreach( $ll in $ctx.Web.Lists)
- {
-
- $ctx.Load($ll.ContentTypes)
-
- try
- {
- $ctx.ExecuteQuery()
- }
- catch
- {
- }
-
-
-
-
-
-
- foreach($cc in $ll.ContentTypes)
- {
-
- if($cc.Name -eq $ContentTypeName){
- $obj = New-Object PSObject
- $obj | Add-Member NoteProperty Title($cc.Name)
- $obj | Add-Member NoteProperty List($ll.Title)
- $obj | Add-Member NoteProperty Web($url)
-
- Write-Output $obj
- }
- }
-
-
- }
-
-
-
- if($ctx.Web.Webs.Count -gt 0)
- {
- foreach ($web in $ctx.Web.Webs)
- {
- Get-SPOContentType -Username $Username -Url $web.Url -AdminPassword $AdminPassword -ContentTypeName $ContentTypeName
- }
- }
-
-
-
- }
+ )
+
+ $ctx=New-Object Microsoft.SharePoint.Client.ClientContext($Url)
+ $ctx.Credentials = New-Object Microsoft.SharePoint.Client.SharePointOnlineCredentials($Username, $AdminPassword)
+ $ctx.ExecuteQuery()
+
+ $ctx.Load($ctx.Web.Lists)
+ $ctx.Load($ctx.Web.Webs)
+ $ctx.ExecuteQuery()
+ Write-Host
+ Write-Host $ctx.Url -BackgroundColor White -ForegroundColor DarkGreen
+
+ foreach( $ll in $ctx.Web.Lists){
+ $ctx.Load($ll.ContentTypes)
+
+ try{
+ $ctx.ExecuteQuery()
+ }
+ catch{}
+
+ foreach($cc in $ll.ContentTypes){
+ if($cc.Name -eq $ContentTypeName){
+ $obj = New-Object PSObject
+ $obj | Add-Member NoteProperty Title($cc.Name)
+ $obj | Add-Member NoteProperty List($ll.Title)
+ $obj | Add-Member NoteProperty Web($url)
+
+ Write-Output $obj
+ }
+ }
+ }
+
+ if($ctx.Web.Webs.Count -gt 0){
+ foreach ($web in $ctx.Web.Webs){
+ Get-SPOContentType -Username $Username -Url $web.Url -AdminPassword $AdminPassword -ContentTypeName $ContentTypeName
+ }
+ }
+}
diff --git a/Content Types/Get/Lists where a given content type is added/description.md b/Content Types/Get/Lists where a given content type is added/description.md
index 18724069..164126df 100644
--- a/Content Types/Get/Lists where a given content type is added/description.md
+++ b/Content Types/Get/Lists where a given content type is added/description.md
@@ -1,12 +1,8 @@
A short script to find all lists across a site collection and its subsites where a given content is added
-
-
Very useful if you receive an error message:
-
-
-
+
when trying to remove a content type.
@@ -16,13 +12,11 @@ when trying to remove a content type.
-How to use?
-
-
+### *How to use?*
-1. Download and install SharePoint Online SDK.
+1. Download and install [SharePoint Online SDK](https://www.microsoft.com/en-us/download/details.aspx?id=42038).
-2. Download the .ps1 file.
+2. Download the *.ps1* file.
3. Open the file (you can do it also in NotePad)
@@ -32,7 +26,7 @@ How to use?
-PowerShell
+```PowerShell
# Paths to SDK. Please verify location on your computer.
Add-Type -Path "c:\Program Files\Common Files\microsoft shared\Web Server Extensions\15\ISAPI\Microsoft.SharePoint.Client.dll"
Add-Type -Path "c:\Program Files\Common Files\microsoft shared\Web Server Extensions\15\ISAPI\Microsoft.SharePoint.Client.Runtime.dll"
@@ -41,37 +35,21 @@ Add-Type -Path "c:\Program Files\Common Files\microsoft shared\Web Server Extens
$Username="admin@tenant.onmicrosoft.com"
$AdminPassword=Read-Host -Prompt "Password" -AsSecureString
$AdminUrl="https://tenant.sharepoint.com/sites/teamsitewithlibraries"
-
-a) Find on your computer where SharePoint.Clitent.dll and SharePoint.Client.Runtime.dll libraries are located and insert the correct paths
-b) Instead of "admin@tenant.onmicrosoft.com" enter you username
-c) Instead of "https://tenant.sharepoint.com/sites/teamsitewithlibraries" enter the name of the site collection where you want to find the content types
-
-
-
+ ```
+a) Find on your computer where SharePoint.Clitent.dll and SharePoint.Client.Runtime.dll libraries are located and insert the correct paths
+b) Instead of "admin@tenant.onmicrosoft.com" enter you username
+c) Instead of "https://tenant.sharepoint.com/sites/teamsitewithlibraries" enter the name of the site collection where you want to find the content types
5. Run the script in Powershell (any module).
6. The result should show the table of names of the associated lists and websites where those lists are located
-
-
-
-
-
-
-
+
You can also export it to CSV:
-
-
-
-
-
-
-
-
+
-Enjoy and please share feedback!
\ No newline at end of file
+Enjoy and please share feedback!
diff --git a/Content Types/Get/Verify the content types used in your lists against the default ones/ModifyDisplayFormTemplateName-ReturnToAllDefault-Verify.ps1 b/Content Types/Get/Verify the content types used in your lists against the default ones/ModifyDisplayFormTemplateName-ReturnToAllDefault-Verify.ps1
index 6904a0a3..58d667c7 100644
--- a/Content Types/Get/Verify the content types used in your lists against the default ones/ModifyDisplayFormTemplateName-ReturnToAllDefault-Verify.ps1
+++ b/Content Types/Get/Verify the content types used in your lists against the default ones/ModifyDisplayFormTemplateName-ReturnToAllDefault-Verify.ps1
@@ -1,59 +1,44 @@
-function Set-SPOContentType
-{
-
- param (
- [Parameter(Mandatory=$true,Position=1)]
- [string]$Username,
- [Parameter(Mandatory=$true,Position=2)]
- $AdminPassword,
- [Parameter(Mandatory=$true,Position=3)]
- [string]$Url
- )
-
- $ctx=New-Object Microsoft.SharePoint.Client.ClientContext($Url)
- $ctx.Credentials = New-Object Microsoft.SharePoint.Client.SharePointOnlineCredentials($Username, $AdminPassword)
- $listy=$ctx.Web.Lists
- $ctx.Load($listy)
- $ctx.ExecuteQuery()
-
-
- $defaultoweFormaty=Import-Csv C:\Users\ivo\Desktop\Book1.csv
- Write-Host $defaultoweFormaty[5].DisplayFormTemplateName
- foreach($ll in $listy)
- {
- $ctx.Load($ll.ContentTypes)
- $ctx.ExecuteQuery()
-
-
- foreach($cc in $ll.ContentTypes)
- {
-
- $opo=$defaultoweFormaty | where {$_.Name -eq $cc.Name}
- Write-Host $ll.Title -ForegroundColor Green
- Write-Host $opo.DisplayFormTemplateName
- Write-Host $cc.DisplayFormTemplateName
- Write-Host "----------------------------------------------------"
- # $cc.DisplayFormTemplateName="DocumentLibraryForm"
- # $cc.Update($false)
- # $ctx.ExecuteQuery()
-
-
+function Set-SPOContentType{
+ param (
+ [Parameter(Mandatory=$true,Position=1)]
+ [string]$Username,
+ [Parameter(Mandatory=$true,Position=2)]
+ $AdminPassword,
+ [Parameter(Mandatory=$true,Position=3)]
+ [string]$Url
+ )
+
+ $ctx=New-Object Microsoft.SharePoint.Client.ClientContext($Url)
+ $ctx.Credentials = New-Object Microsoft.SharePoint.Client.SharePointOnlineCredentials($Username, $AdminPassword)
+ $listy=$ctx.Web.Lists
+ $ctx.Load($listy)
+ $ctx.ExecuteQuery()
+
+ $defaultoweFormaty=Import-Csv C:\Users\ivo\Desktop\Book1.csv
+ Write-Host $defaultoweFormaty[5].DisplayFormTemplateName
+
+ foreach($ll in $listy)
+ {
+ $ctx.Load($ll.ContentTypes)
+ $ctx.ExecuteQuery()
+
+ foreach($cc in $ll.ContentTypes){
+ $opo=$defaultoweFormaty | where {$_.Name -eq $cc.Name}
+ Write-Host $ll.Title -ForegroundColor Green
+ Write-Host $opo.DisplayFormTemplateName
+ Write-Host $cc.DisplayFormTemplateName
+ Write-Host "----------------------------------------------------"
+ # $cc.DisplayFormTemplateName="DocumentLibraryForm"
+ # $cc.Update($false)
+ # $ctx.ExecuteQuery()
+ }
+ }
+
+ $ctx.Dispose()
}
-
- }
-
- $ctx.Dispose()
-
-
- }
-
-
-
-
-
-
+
# Paths to SDK. Please verify location on your computer.
Add-Type -Path "c:\Program Files\Common Files\microsoft shared\Web Server Extensions\15\ISAPI\Microsoft.SharePoint.Client.dll"
diff --git a/Content Types/Get/Verify the content types used in your lists against the default ones/description.md b/Content Types/Get/Verify the content types used in your lists against the default ones/description.md
index 2b6737ef..ac72374b 100644
--- a/Content Types/Get/Verify the content types used in your lists against the default ones/description.md
+++ b/Content Types/Get/Verify the content types used in your lists against the default ones/description.md
@@ -1,30 +1,15 @@
The script is part of the explanation on editing the content types available in the article here:
-SharePoint Online content types in Powershell: Edit.
+[SharePoint Online content types in Powershell: Edit.](https://social.technet.microsoft.com/wiki/contents/articles/31444.sharepoint-online-content-types-in-powershell-edit.aspx)
-
This example loops through all lists in a single site and verifies the content types against default content types from a CSV file. You need to provide the CSV file. In order to retrieve all content types from the Content Type Hub, you can use the following scripts:
-Retrieve all Content Types from a Content Type Hub and their DisplayFormTemplate - click here for direct download
-
-Get all properties of all content types in a SharePoint site - click here for direct download
-
-
-
-
+[Retrieve all Content Types from a Content Type Hub and their DisplayFormTemplate](https://gallery.technet.microsoft.com/Retrieve-all-Content-Types-31f14c8b) - click [here](https://gallery.technet.microsoft.com/Get-all-properties-of-all-3a9c5c4b/file/137804/1/ContentTypesWithoutPSObjectWithoutEXtraProperties.ps1) for direct download
-
+[Get all properties of all content types in a SharePoint site](https://gallery.technet.microsoft.com/Get-all-properties-of-all-3a9c5c4b) - click [here](https://gallery.technet.microsoft.com/Get-all-properties-of-all-3a9c5c4b/file/137804/1/ContentTypesWithoutPSObjectWithoutEXtraProperties.ps1) for direct download
-
-
-
-
-The script requires SharePoint Online SDK installed. Before running the script, enter the information:
-
-
-
-
+The script requires [SharePoint Online SDK](https://www.microsoft.com/en-us/download/details.aspx?id=42038) installed. Before running the script, enter the information:
```PowerShell
$defaultoweFormaty=Import-Csv C:\Users\ivo\Desktop\Book1.csv
diff --git a/Content Types/README.md b/Content Types/README.md
new file mode 100644
index 00000000..8b137891
--- /dev/null
+++ b/Content Types/README.md
@@ -0,0 +1 @@
+
diff --git a/Versioning/PS Enable versioning for all SharePoint Online lists/description.md b/File Management/Readme.md
similarity index 100%
rename from Versioning/PS Enable versioning for all SharePoint Online lists/description.md
rename to File Management/Readme.md
diff --git a/File Management/Records Management/Declare files as records/DeclareAsRecord.ps1 b/File Management/Records Management/Declare files as records/DeclareAsRecord.ps1
new file mode 100644
index 00000000..a1366716
--- /dev/null
+++ b/File Management/Records Management/Declare files as records/DeclareAsRecord.ps1
@@ -0,0 +1,82 @@
+function Declare-Record
+{
+param (
+ [Parameter(Mandatory=$true,Position=1)]
+ [string]$Username,
+ [Parameter(Mandatory=$true,Position=2)]
+ [string]$Url,
+ [Parameter(Mandatory=$true,Position=3)]
+ $password,
+ [Parameter(Mandatory=$true,Position=4)]
+ [string]$ListTitle
+ )
+
+
+ $ctx=New-Object Microsoft.SharePoint.Client.ClientContext($url)
+ [Microsoft.SharePOint.Client.ClientRuntimeContext] $rctx=[Microsoft.SharePoint.Client.ClientRuntimeContext]$ctx.Site.Context
+ $ctx.Credentials = New-Object Microsoft.SharePoint.Client.SharePointOnlineCredentials($Username, $password)
+ $ctx.Load($ctx.Web)
+ $ctx.ExecuteQuery()
+ $ll=$ctx.Web.Lists.GetByTitle($ListTitle)
+ $ctx.Load($ll)
+ $ctx.ExecuteQuery()
+ $spqQuery = New-Object Microsoft.SharePoint.Client.CamlQuery
+ $spqQuery.ViewXml ="/VersionTest/Folder2/FolderWithinFolder";
+ $itemki=$ll.GetItems($spqQuery)
+ $ctx.Load($itemki)
+ $ctx.ExecuteQuery()
+
+ foreach($item in $itemki)
+ {
+ Write-Host "Processing item no " $item.ID
+ $ctx.Load($item)
+ $ctx.Load($item.File)
+ $ctx.ExecuteQuery()
+ [Boolean] $bool=[Microsoft.SharePoint.Client.RecordsRepository.Records]::IsRecord($rctx, $item)
+
+ if(!$bool)
+ {
+ [Microsoft.SharePoint.Client.RecordsRepository.Records]::DeclareItemAsRecord($rctx,$item)
+ $ctx.ExecuteQuery()
+ Write-host $item.File.Name " " $item.File.ServerRelativeUrl "has been declared as a record" -ForegroundColor Green
+ }
+ else
+ {
+ Write-Host $item.File.Name " " $item.File.ServerRelativeUrl " is already a record." -ForegroundColor Red
+ }
+
+
+ }
+
+
+
+
+
+
+
+ }
+
+
+
+
+
+
+
+
+
+#Paths to SDK
+Add-Type -Path "H:\Libraries\Microsoft.SharePoint.Client.dll"
+Add-Type -Path "H:\Libraries\Microsoft.SharePoint.Client.Runtime.dll"
+Add-Type -Path "H:\Libraries\Microsoft.Office.Client.Policy.dll"
+#Add-Type -Path "c:\Program Files\Common Files\microsoft shared\Web Server Extensions\16\ISAPI\Microsoft.SharePoint.Client.Runtime.dll"
+
+
+#Enter the data
+$AdminPassword=Read-Host -Prompt "Enter password" -AsSecureString
+$username="t@testova365.onmicrosoft.com"
+$Url="https://testova365.sharepoint.com/sites/STS"
+$ListTitle="VersionTest"
+
+
+
+Declare-Record -Username $username -Url $Url -password $AdminPassword -ListTitle $ListTitle
\ No newline at end of file
diff --git a/File Management/Records Management/Declare files as records/description.md b/File Management/Records Management/Declare files as records/description.md
new file mode 100644
index 00000000..8cb80003
--- /dev/null
+++ b/File Management/Records Management/Declare files as records/description.md
@@ -0,0 +1,38 @@
+A short script to declare all items from a list as records.
+
+
+
+The script retrieves all items from the list, verifies whether they are not declared as records, and if yes, declares them.
+
+While executing, it displays the Name and Server Relative Url of the files.
+
+
+
+
+
+The script requires the newest libraries. The required libraries can be downloaded from
+
+https://www.microsoft.com/en-us/download/details.aspx?id=42038
+
+
+
+
+
+You need to enter your tenant's data before running the script and paths to SDK.
+
+
+
+```PowerShell
+#Paths to SDK
+Add-Type -Path "H:\Libraries\Microsoft.SharePoint.Client.dll"
+Add-Type -Path "H:\Libraries\Microsoft.SharePoint.Client.Runtime.dll"
+Add-Type -Path "H:\Libraries\Microsoft.Office.Client.Policy.dll"
+
+
+
+#Enter the data
+$AdminPassword=Read-Host -Prompt "Enter password" -AsSecureString
+$username="t@testova365.onmicrosoft.com"
+$Url="https://testova365.sharepoint.com/sites/STS"
+$ListTitle="VersionTest"
+```
diff --git a/File Management/Records Management/Undeclare files as records/description.md b/File Management/Records Management/Undeclare files as records/description.md
new file mode 100644
index 00000000..ccd4ac7f
--- /dev/null
+++ b/File Management/Records Management/Undeclare files as records/description.md
@@ -0,0 +1,34 @@
+A short script to undeclare all records from a list.
+
+
+
+The script retrieves all items from the list, verifies whether they are declared as records, and if yes, undeclares them.
+
+While executing, it displays the Name and Server Relative Url of the files.
+
+
+
+
+
+The script requires the newest libraries. The required libraries can be downloaded from https://www.nuget.org/packages/Microsoft.SharePointOnline.CSOM/
+
+
+
+You need to enter your tenant's data before running the script and paths to SDK.
+
+
+
+```PowerShell
+#Paths to SDK
+Add-Type -Path "H:\Libraries\Microsoft.SharePoint.Client.dll"
+Add-Type -Path "H:\Libraries\Microsoft.SharePoint.Client.Runtime.dll"
+Add-Type -Path "H:\Libraries\Microsoft.Office.Client.Policy.dll"
+
+
+
+#Enter the data
+$AdminPassword=Read-Host -Prompt "Enter password" -AsSecureString
+$username="t@testova365.onmicrosoft.com"
+$Url="https://testova365.sharepoint.com/sites/STS"
+$ListTitle="VersionTest"
+```
diff --git a/File Management/Records Management/Undeclare files as records/undeclareAsRecords.ps1 b/File Management/Records Management/Undeclare files as records/undeclareAsRecords.ps1
new file mode 100644
index 00000000..c1648b80
--- /dev/null
+++ b/File Management/Records Management/Undeclare files as records/undeclareAsRecords.ps1
@@ -0,0 +1,71 @@
+function Declare-Record
+{
+param (
+ [Parameter(Mandatory=$true,Position=1)]
+ [string]$Username,
+ [Parameter(Mandatory=$true,Position=2)]
+ [string]$Url,
+ [Parameter(Mandatory=$true,Position=3)]
+ $password,
+ [Parameter(Mandatory=$true,Position=4)]
+ [string]$ListTitle
+ )
+
+
+ $ctx=New-Object Microsoft.SharePoint.Client.ClientContext($url)
+ [Microsoft.SharePOint.Client.ClientRuntimeContext] $rctx=[Microsoft.SharePoint.Client.ClientRuntimeContext]$ctx.Site.Context
+ $ctx.Credentials = New-Object Microsoft.SharePoint.Client.SharePointOnlineCredentials($Username, $password)
+ $ctx.Load($ctx.Web)
+ $ctx.ExecuteQuery()
+ $ll=$ctx.Web.Lists.GetByTitle($ListTitle)
+ $ctx.Load($ll)
+ $ctx.ExecuteQuery()
+ $spqQuery = New-Object Microsoft.SharePoint.Client.CamlQuery
+ $spqQuery.ViewXml ="/VersionTest/Folder2/FolderWithinFolder";
+ $itemki=$ll.GetItems($spqQuery)
+ $ctx.Load($itemki)
+ $ctx.ExecuteQuery()
+
+ foreach($item in $itemki)
+ {
+ Write-Host "Processing item no " $item.ID
+ $ctx.Load($item)
+ $ctx.Load($item.File)
+ $ctx.ExecuteQuery()
+ [Boolean] $bool=[Microsoft.SharePoint.Client.RecordsRepository.Records]::IsRecord($rctx, $item)
+
+ if($bool)
+ {
+ [Microsoft.SharePoint.Client.RecordsRepository.Records]::UnDeclareItemAsRecord($rctx,$item)
+ $ctx.ExecuteQuery()
+ Write-host $item.File.Name " " $item.File.ServerRelativeUrl "has been undeclared as a record" -ForegroundColor Green
+ }
+ else
+ {
+ Write-Host $item.File.Name " " $item.File.ServerRelativeUrl " is not a record." -ForegroundColor Red
+ }
+
+ }
+
+}
+
+
+
+
+
+#Paths to SDK
+Add-Type -Path "H:\Libraries\Microsoft.SharePoint.Client.dll"
+Add-Type -Path "H:\Libraries\Microsoft.SharePoint.Client.Runtime.dll"
+Add-Type -Path "H:\Libraries\Microsoft.Office.Client.Policy.dll"
+#Add-Type -Path "c:\Program Files\Common Files\microsoft shared\Web Server Extensions\16\ISAPI\Microsoft.SharePoint.Client.Runtime.dll"
+
+
+#Enter the data
+$AdminPassword=Read-Host -Prompt "Enter password" -AsSecureString
+$username="t@testova365.onmicrosoft.com"
+$Url="https://testova365.sharepoint.com/sites/STS"
+$ListTitle="VersionTest"
+
+
+
+Declare-Record -Username $username -Url $Url -password $AdminPassword -ListTitle $ListTitle
diff --git a/File Management/Restore previous versions in selected files the entire library/RestorePreviousVersionsInSelectedFiles.ps1 b/File Management/Restore previous versions in selected files the entire library/RestorePreviousVersionsInSelectedFiles.ps1
new file mode 100644
index 00000000..67a8430b
--- /dev/null
+++ b/File Management/Restore previous versions in selected files the entire library/RestorePreviousVersionsInSelectedFiles.ps1
@@ -0,0 +1,116 @@
+function Get-SPOFolderFiles
+{
+param (
+ [Parameter(Mandatory=$true,Position=1)]
+ [string]$Username,
+ [Parameter(Mandatory=$true,Position=2)]
+ [string]$Url,
+ [Parameter(Mandatory=$true,Position=3)]
+ $password,
+ [Parameter(Mandatory=$true,Position=4)]
+ [string]$ListTitle
+ )
+
+
+ $ctx=New-Object Microsoft.SharePoint.Client.ClientContext($Url)
+ $ctx.Credentials = New-Object Microsoft.SharePoint.Client.SharePointOnlineCredentials($Username, $password)
+ $ctx.Load($ctx.Web)
+ $ctx.ExecuteQuery()
+ $ll=$ctx.Web.Lists.GetByTitle($ListTitle)
+ $ctx.Load($ll)
+ $ctx.ExecuteQuery()
+ $spqQuery = New-Object Microsoft.SharePoint.Client.CamlQuery
+ $spqQuery.ViewXml ="/VersionTest/Folder2/FolderWithinFolder";
+ $itemki=$ll.GetItems($spqQuery)
+ $ctx.Load($itemki)
+ $ctx.ExecuteQuery()
+
+ foreach($item in $itemki)
+ {
+
+
+ # Write-Host $item["FileRef"] -ForegroundColor DarkGreen
+ $file =
+ $ctx.Web.GetFileByServerRelativeUrl($item["FileRef"]);
+ $ctx.Load($file)
+ $ctx.Load($file.Versions)
+ try{
+ $ctx.ExecuteQuery() }
+ catch
+ {
+ continue;
+ }
+
+ #$file.TimeLastModified
+ $date=Get-Date ("2/12/2017")
+
+ if($file.TimeLastModified -gt $date)
+ {
+
+ Write-host $file.Name -ForegroundColor Green
+ if ($file.Versions.Count -eq 0)
+ {
+ $obj=New-Object PSObject
+ $obj | Add-Member NoteProperty ServerRelativeUrl($file.ServerRelativeUrl)
+ $obj | Add-Member NoteProperty FileLeafRef($item["FileLeafRef"])
+ $obj | Add-Member NoteProperty Versions("No Versions Available")
+
+ #$obj | export-csv -Path $CSVPath -Append
+
+ Write-Output $obj
+ }
+ elseif($file.TypedObject.ToString() -eq "Microsoft.SharePoint.Client.File")
+ {
+
+ foreach ($vv in $file.Versions){
+ Write-Host $vv.Created $vv.Size $vv.VersionLabel $vv.IsCurrentVersion $file.Versions.Count
+
+ # Write-Output $vv
+
+ }
+ if($file.Versions[($file.Versions.Count-1)].IsCurrentVersion)
+ {
+ $vLabel=$file.Versions[($file.Versions.Count-2)].VersionLabel
+ Write-Host "Version to be restored: " $vLabel
+ }
+ else{ $vLabel=$file.Versions[($file.Versions.Count-1)].VersionLabel
+ Write-Host "Version to be restored: " $vLabel }
+ $file.Versions.RestoreByLabel($vLabel)
+ $ctx.ExecuteQuery()
+ }
+
+ else
+ {
+$obj = New-Object PSObject
+$obj| Add-Member NoteProperty FileLeafRef($item["FileLeafRef"])
+ $obj | Add-Member NoteProperty Versions("No Versions Available")
+ Write-Output $obj
+ }
+
+
+ }
+
+
+ }
+
+
+
+
+
+
+
+}
+
+#Paths to SDK
+Add-Type -Path "c:\Program Files\Common Files\microsoft shared\Web Server Extensions\15\ISAPI\Microsoft.SharePoint.Client.dll"
+Add-Type -Path "c:\Program Files\Common Files\microsoft shared\Web Server Extensions\15\ISAPI\Microsoft.SharePoint.Client.Runtime.dll"
+
+#Enter the data
+$AdminPassword=Read-Host -Prompt "Enter password" -AsSecureString
+$username="t@testova365.onmicrosoft.com"
+$Url="https://testova365.sharepoint.com/sites/STS"
+$ListTitle="VersionTest"
+
+
+
+Get-sPOFolderFiles -Username $username -Url $Url -password $AdminPassword -ListTitle $ListTitle
\ No newline at end of file
diff --git a/File Management/Restore previous versions in selected files the entire library/description.md b/File Management/Restore previous versions in selected files the entire library/description.md
new file mode 100644
index 00000000..b3d3567b
--- /dev/null
+++ b/File Management/Restore previous versions in selected files the entire library/description.md
@@ -0,0 +1,55 @@
+The script retrieves all files and restores the LAST NOT CURRENT version of the file.
+
+Please test the script in test environment before using it in production.
+
+
+
+The script is a modification of the existing Restore Previous Versions script created to show 2 ways on filtering the file results. The filters are only examples that need to be adjusted to your specific needs.
+
+The first filter uses CamlQuery to retrieve only files coming from a specific folder.
+
+The second filter takes files we have already retrieved and selects only those modified after 12/2/2017.
+
+When dealing with large number of files CamlQuery is the preferred and more efficient way.
+
+
+
+
+
+ The script requires SharePoint Online SDK. Make sure that the paths below point to locations on your computer:
+
+
+
+PowerShell
+#Paths to SDK
+Add-Type -Path "c:\Program Files\Common Files\microsoft shared\Web Server Extensions\15\ISAPI\Microsoft.SharePoint.Client.dll"
+Add-Type -Path "c:\Program Files\Common Files\microsoft shared\Web Server Extensions\15\ISAPI\Microsoft.SharePoint.Client.Runtime.dll"
+
+
+
+
+
+
+
+The script needs to be edited before running. Enter the necessary data:
+
+
+
+```PowerShell
+#Enter the data
+$AdminPassword=Read-Host -Prompt "Enter password" -AsSecureString
+$username="t@testova365.onmicrosoft.com"
+$Url="https://testova365.sharepoint.com/sites/STS"
+$ListTitle="VersionTest"
+```
+The CamlQuery below chooses only files whose ServerRelativeUrl includes a certain path. In this way you can restore versions only from a specific folder.
+PowerShell
+ $spqQuery.ViewXml ="/VersionTest/Folder2/FolderWithinFolder";
+
+ The following lines allow us to narrow the files only to those modified after 12/2/2017.
+PowerShell
+ $date=Get-Date ("2/12/2017")
+
+ if($file.TimeLastModified -gt $date)
+ {
+
diff --git a/Getting SPO objects with REST/Module for getting SharePoint Online objects with Powershell/Untitled11.png b/Getting SPO objects with REST/Module for getting SharePoint Online objects with Powershell/Untitled11.png
new file mode 100644
index 00000000..c3202a9d
Binary files /dev/null and b/Getting SPO objects with REST/Module for getting SharePoint Online objects with Powershell/Untitled11.png differ
diff --git a/Getting SPO objects with REST/Module for getting SharePoint Online objects with Powershell/Untitled12.png b/Getting SPO objects with REST/Module for getting SharePoint Online objects with Powershell/Untitled12.png
new file mode 100644
index 00000000..d3e0982a
Binary files /dev/null and b/Getting SPO objects with REST/Module for getting SharePoint Online objects with Powershell/Untitled12.png differ
diff --git a/Getting SPO objects with REST/Module for getting SharePoint Online objects with Powershell/Untitled13.png b/Getting SPO objects with REST/Module for getting SharePoint Online objects with Powershell/Untitled13.png
new file mode 100644
index 00000000..26971b8f
Binary files /dev/null and b/Getting SPO objects with REST/Module for getting SharePoint Online objects with Powershell/Untitled13.png differ
diff --git a/Getting SPO objects with REST/Module for getting SharePoint Online objects with Powershell/description.md b/Getting SPO objects with REST/Module for getting SharePoint Online objects with Powershell/description.md
new file mode 100644
index 00000000..59fc6862
--- /dev/null
+++ b/Getting SPO objects with REST/Module for getting SharePoint Online objects with Powershell/description.md
@@ -0,0 +1,104 @@
+Powershell module with Get-SPOObject cmdlet to retrieve SharePoint Online objects, such as
+
+lists
+content types
+fields/columns
+alerts
+event receivers
+features
+site groups
+users
+workflow associations
+
+
+How does it work?
+
+
+1. Download the file and import the module.
+
+2. Run the cmdlet.
+
+
+
+
+
+
+
+Sample uses:
+
+
+
+PowerShell
+Get-SPOObject -Username t@t321.onmicrosoft.com -password $password -url https://t321.sharepoint.com/standard -object "lists/getbytitle('biblioteka')/files"
+
+
+
+
+
+
+
+
+
+
+
+
+
+PowerShell
+Get-SPOObject -Username t@t321.onmicrosoft.com -password $password -url https://t321.sharepoint.com/standard -object "lists/getbytitle('biblioteka')/files" | where {$_.CreatedBy.Name -eq "Ana Trial"}
+
+PowerShell
+Get-SPOObject -Username t@t321.onmicrosoft.com -password $password -url https://t321.sharepoint.com/standard -object "allproperties"
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+PowerShell
+ Get-SPOObject -Username t@t321.onmicrosoft.com -password $password -url https://t321.sharepoint.com/standard -object ""
+
+
+
+
+
+
+
+
+
+
+
+
+
+You can find this Powershell module in 2 other versions:
+
+- one with suggestions, limited but helpful when you are starting and don't know what your options are
+
+Module for getting SharePoint Online objects with Powershell (limited)
+
+- one free-style allowing you to pull anything under /_api/ , so not only web but also site objects
+
+Module for getting SharePoint Online objects with Powershell (unrestricted)
+
+
+
+
+There is also a script available under:
+
+Get SharePoint Online objects with REST
+
+
+
+
diff --git a/Getting SPO objects with REST/Module for getting SharePoint Online objects with Powershell/getSPOobjectWithRestModule.psm1 b/Getting SPO objects with REST/Module for getting SharePoint Online objects with Powershell/getSPOobjectWithRestModule.psm1
new file mode 100644
index 00000000..616132c4
--- /dev/null
+++ b/Getting SPO objects with REST/Module for getting SharePoint Online objects with Powershell/getSPOobjectWithRestModule.psm1
@@ -0,0 +1,68 @@
+function Get-SPOObject
+{
+param (
+ [Parameter(Mandatory=$true,Position=1)]
+ [string]$Username,
+ [Parameter(Mandatory=$true,Position=2)]
+ [SecureString] $password = (Read-Host -AsSecureString),
+ [Parameter(Mandatory=$true,Position=3)]
+ [string] $url,
+ [Parameter(Mandatory=$false,Position=4)]
+ [string] $object=""
+ )
+
+
+
+ $Credentials = New-Object Microsoft.SharePoint.Client.SharePointOnlineCredentials($Username, $password)
+ $RestUrl=$url+"/_api/web/"
+ if($object -ne "")
+ {
+ $RestUrl+=$object
+ }
+
+
+
+ $request = [System.Net.WebRequest]::Create($RESTUrl)
+ $request.Credentials = $Credentials
+ $request.Headers.Add("X-FORMS_BASED_AUTH_ACCEPTED", "f")
+ $request.Accept = "application/json;odata=verbose"
+ [Microsoft.PowerShell.Commands.WebRequestMethod]$Method = [Microsoft.PowerShell.Commands.WebRequestMethod]::Get
+ $request.Method=$Method
+ $response = $request.GetResponse()
+ $requestStream = $response.GetResponseStream()
+ $read = New-Object System.IO.StreamReader $requestStream
+ $data=$read.ReadToEnd()
+ $results = $data | ConvertFrom-Json
+ $objekty=$results.d.results
+
+
+
+ if($objekty -ne $null)
+ {
+ Write-Output $objekty
+ }
+ else
+ {
+ Write-Output $results.d
+
+ }
+
+
+
+
+ }
+
+
+
+Add-Type -Path "c:\Program Files\Common Files\microsoft shared\Web Server Extensions\16\ISAPI\Microsoft.SharePoint.Client.dll"
+Add-Type -Path "c:\Program Files\Common Files\microsoft shared\Web Server Extensions\16\ISAPI\Microsoft.SharePoint.Client.Runtime.dll"
+
+
+#Enter the data
+#$AdminPassword=Read-Host -Prompt "Enter password" -AsSecureString
+#$username="t@t321.onmicrosoft.com"
+#$Url="https://t321.sharepoint.com/standard"
+
+
+Export-ModuleMember "Get-SPOObject"
+
diff --git a/Items Management/Get the number of items in a list/description.md b/Items Management/Get the number of items in a list/description.md
index 6261abca..b54e0377 100644
--- a/Items Management/Get the number of items in a list/description.md
+++ b/Items Management/Get the number of items in a list/description.md
@@ -7,16 +7,16 @@ New SharePoint Online Powershell cmdlet Get-SPOListItemCount which allows you to
The cmdlet is using the following parameters:
- [string]$Username
+ ```[string]$Username```
The string specifies admin of the site
-[string]$Url
+```[string]$Url```
Specifies the url of a site where you have the list
-[string]$AdminPassword,
+```[string]$AdminPassword```
Admin's password
-[string]$ListTitle
+```PowerShell[string]$ListTitle```
Specifies the title of a list
@@ -29,8 +29,7 @@ Specifies the title of a list
The following libraries (SharePoint Online SDK) are required. If those libraries are in different location on your computer, please edit the .psm1 file!
-```powershell
-PowerShell
+```PowerShell
# Paths to SDK. Please verify location on your computer.
Add-Type -Path "c:\Program Files\Common Files\microsoft shared\Web Server Extensions\15\ISAPI\Microsoft.SharePoint.Client.dll"
Add-Type -Path "c:\Program Files\Common Files\microsoft shared\Web Server Extensions\15\ISAPI\Microsoft.SharePoint.Client.Runtime.dll"
diff --git a/Licensing/Check User Licenses using plan type/description.md b/Licensing/Check User Licenses using plan type/description.md
index cbd2846c..2ba87a73 100644
--- a/Licensing/Check User Licenses using plan type/description.md
+++ b/Licensing/Check User Licenses using plan type/description.md
@@ -14,7 +14,7 @@ https://gallery.technet.microsoft.com/Check-user-licenses-using-461b317c
-How to use?
+### How to use?
1. Make sure you have installed Azure AD module available here: https://msdn.microsoft.com/en-us/library/azure/jj151815(v=azure.98).aspx
@@ -24,21 +24,21 @@ How to use?
-PowerShell
+```PowerShell
$PlanToCheck="Exchange"
$CSVPath="" #E:\technet\UsersWithDisabledEXO.csv Enter only if you want to export to csv
$ChecksWhetherThePlanIs="Disabled" #Disabled, Success or PendingActivation
+```
-
-<#Plans to choose from. Please enter only one value above
-ProjectWorkManagement
-Sway
-SCO
-YammerEnterprise
-RMSOnline
-MicrosoftOffice
-MicrosoftCommunicationsOnline
-Exchange
+Plans to choose from. Please enter only one value above
+* ProjectWorkManagement
+* Sway
+* SCO
+* YammerEnterprise
+* RMSOnline
+* MicrosoftOffice
+* MicrosoftCommunicationsOnline
+* Exchange
@@ -48,18 +48,18 @@ In $CSVPath leave as it is if you don't want a csv report, or if you do, enter p
-PowerShell
+```PowerShell
$CSVPath="E:\technet\UsersWithDisabledEXO.csv"
-
+```
-$ChecksWhetherThePlanIs if set to "Disable" (as it is) will check for all disabled plans. If you want to check successfully provisioned or pending activation, enter "Success" or "PendingActivation". Important! Disabled are only the services where you assigned the license but not all services are active (e.g. E3 is assigned, but Exchange Online is unmarked). See example below:
+```$ChecksWhetherThePlanIs ``` if set to "Disable" (as it is) will check for all disabled plans. If you want to check successfully provisioned or pending activation, enter "Success" or "PendingActivation". Important! Disabled are only the services where you assigned the license but not all services are active (e.g. E3 is assigned, but Exchange Online is unmarked). See example below:
Here the license is disabled:
-
+
@@ -68,7 +68,7 @@ Here the license is disabled:
Here it is NOT:
-
+
@@ -76,3 +76,7 @@ Here it is NOT:
4. Save the script and drag&drop it to Powershell. It will ask you for credentials and display a list of users on the screen.
+
+
+
+Enjoy and please share feedback!
\ No newline at end of file
diff --git a/Licensing/Check user licenses using Service Name/description.md b/Licensing/Check user licenses using Service Name/description.md
index a0ff785c..f4b3b1d4 100644
--- a/Licensing/Check user licenses using Service Name/description.md
+++ b/Licensing/Check user licenses using Service Name/description.md
@@ -36,7 +36,7 @@ EXCHANGE_S_ENTERPRISE
-How to use?
+### How to use?
1. Make sure you have installed Azure AD module available here: https://msdn.microsoft.com/en-us/library/azure/jj151815(v=azure.98).aspx
@@ -44,7 +44,7 @@ How to use?
3. In the first lines you see:
-PowerShell
+```PowerShell
<# Possible serviceNames:
PROJECTWORKMANAGEMENT
SWAY
@@ -71,15 +71,15 @@ If you think a service name is missing from the list above, you can use the foll
$PlanToCheck="Exchange_S_ENTERPRISE"
$CSVPath="" #Enter only if you want to export to csv, e.g. E:\technet\UsersWithDisabledEXO.csv
$ChecksWhetherThePlanIs="Disabled" #Disabled, Success or PendingActivation
-
+```
In $PlanToCheck="Enter the name of the plan you want to check"
In $CSVPath leave it as it is if you don't want a csv report, or if you do want a report, enter the path in inverted commas like in the example below:
-PowerShell
+```PowerShell
$CSVPath="E:\technet\UsersWithDisabledEXO.csv"
-
-$ChecksWhetherThePlanIs if set to "Disable" (as it is) will check for all disabled plans. If you want to check successfully provisioned or pending activation, enter "Success" or "PendingActivation".
+ ```
+``` $ChecksWhetherThePlanIs ``` if set to "Disable" (as it is) will check for all disabled plans. If you want to check successfully provisioned or pending activation, enter "Success" or "PendingActivation".
Important! Disabled are only the services where you assigned the license but not all services are active (e.g. E3 is assigned, but Exchange Online is unmarked). See example below:
@@ -88,7 +88,7 @@ Important! Disabled are only the services where you assigned the license but no
Here the license is disabled:
-
+
@@ -97,10 +97,15 @@ Here it is NOT:
-
+
4. Save the script and drag&drop it to Powershell. It will ask you for credentials and display a list of users on the screen.
+
+
+
+
+Enjoy and please share feedback!
\ No newline at end of file
diff --git a/Lists and Libraries Management/Allow or disallow users to create folders/description.md b/Lists and Libraries Management/Allow or disallow users to create folders/description.md
index a6848719..06b9014b 100644
--- a/Lists and Libraries Management/Allow or disallow users to create folders/description.md
+++ b/Lists and Libraries Management/Allow or disallow users to create folders/description.md
@@ -28,13 +28,13 @@ $EnableFolderCreation=$false
-Results
+### Results
-Related scripts
+### Related scripts
Set direction of the reading order for a single list
Set-SPOList properties (module)
diff --git a/Lists and Libraries Management/Checkout/Powershell/Force your users to checkout documents using Powershell/description.txt b/Lists and Libraries Management/Checkout/Powershell/Force your users to checkout documents using Powershell/description.md
similarity index 92%
rename from Lists and Libraries Management/Checkout/Powershell/Force your users to checkout documents using Powershell/description.txt
rename to Lists and Libraries Management/Checkout/Powershell/Force your users to checkout documents using Powershell/description.md
index 324606e5..3e2c005d 100644
--- a/Lists and Libraries Management/Checkout/Powershell/Force your users to checkout documents using Powershell/description.txt
+++ b/Lists and Libraries Management/Checkout/Powershell/Force your users to checkout documents using Powershell/description.md
@@ -1,64 +1,62 @@
-Powershell module which enables or disables Checkout Requirement for all lists in a given site collection.
-
-It corresponds to the following GUI option:
-
-
-
-
-
-After import you can use Set-Checkout cmdlet with the following parameters:
-
- [string]$Username
-The string specifies admin of a given site collection where you want to enforce Checkout Requirement or disable the enforcement
-
-[string]$Url
-Specifies the url of a site where you want to enable or disable Checkout Requirement for all lists
-
- [bool]$IncludeSubsites=$false,
-Specifies whether the cmdlet should also change the Checkout Requirement in the subsites
-
-[string]$AdminPassword,
-Admin' password
-
-[bool]$ForceCheckout=$true
-Specifies whether the documents should be checked out ($true) or disables the Checkout Requirement ($false).
-
-
-
-Example:
-
-PS C:\Windows\system32> Import-Module d:\Powershell\CheckOutModule2.psm1
-
-PS C:\Windows\system32> Set-Checkout -Username trial@trialtrial123.onmicrosoft.com -Url https://trialtrial123.sharepoint.com/sites/teamsitewithlibraries -IncludeSubsites $true -AdminPassword Password -ForceCheckout $true
-
-
-
-
-
-It uses the following prerequisites. If those libraries are in different location on your computer, please edit the .psm1 file!
-
-
-
-PowerShell
-Add-Type -Path "c:\Program Files\Common Files\microsoft shared\Web Server Extensions\15\ISAPI\Microsoft.SharePoint.Client.dll"
-Add-Type -Path "c:\Program Files\Common Files\microsoft shared\Web Server Extensions\15\ISAPI\Microsoft.SharePoint.Client.Runtime.dll"
-
-
-
-Results:
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
+Powershell module which enables or disables Checkout Requirement for all lists in a given site collection.
+
+It corresponds to the following GUI option:
+
+
+
+
+
+After import you can use Set-Checkout cmdlet with the following parameters:
+
+ [string]$Username
+The string specifies admin of a given site collection where you want to enforce Checkout Requirement or disable the enforcement
+
+[string]$Url
+Specifies the url of a site where you want to enable or disable Checkout Requirement for all lists
+
+ [bool]$IncludeSubsites=$false,
+Specifies whether the cmdlet should also change the Checkout Requirement in the subsites
+
+[string]$AdminPassword,
+Admin' password
+
+[bool]$ForceCheckout=$true
+Specifies whether the documents should be checked out ($true) or disables the Checkout Requirement ($false).
+
+
+
+Example:
+
+PS C:\Windows\system32> Import-Module d:\Powershell\CheckOutModule2.psm1
+
+PS C:\Windows\system32> Set-Checkout -Username trial@trialtrial123.onmicrosoft.com -Url https://trialtrial123.sharepoint.com/sites/teamsitewithlibraries -IncludeSubsites $true -AdminPassword Password -ForceCheckout $true
+
+
+
+
+
+It uses the following prerequisites. If those libraries are in different location on your computer, please edit the .psm1 file!
+
+
+
+```PowerShell
+Add-Type -Path "c:\Program Files\Common Files\microsoft shared\Web Server Extensions\15\ISAPI\Microsoft.SharePoint.Client.dll"
+Add-Type -Path "c:\Program Files\Common Files\microsoft shared\Web Server Extensions\15\ISAPI\Microsoft.SharePoint.Client.Runtime.dll"
+ ```
+
+
+Results:
+
+
+
+
+
+
+
+
+
+
+
+
+
+Enjoy and please share feedback!
\ No newline at end of file
diff --git a/Lists and Libraries Management/Column Management/Add a library column with file name and extension/description.md b/Lists and Libraries Management/Column Management/Add a library column with file name and extension/description.md
index 468a0039..c914d11d 100644
--- a/Lists and Libraries Management/Column Management/Add a library column with file name and extension/description.md
+++ b/Lists and Libraries Management/Column Management/Add a library column with file name and extension/description.md
@@ -30,12 +30,14 @@ The script will not run without editing. Remember to enter the correct data:
Add-Type -Path "c:\Windows\Microsoft.NET\assembly\GAC_MSIL\Microsoft.SharePoint.Client\v4.0_16.0.0.0__71e9bce111e9429c\Microsoft.SharePoint.Client.dll"
Add-Type -Path "c:\Windows\Microsoft.NET\assembly\GAC_MSIL\Microsoft.SharePoint.Client.Runtime\v4.0_16.0.0.0__71e9bce111e9429c\Microsoft.SharePoint.Client.Runtime.dll"
-$pasworde = Read-Host -Prompt "Password " -AsSecureString
+$pasword = Read-Host -Prompt "Password " -AsSecureString
$uss="2190@tenant.onmicrosoft.com"
$listTitle="ext3"
$listID="1979CC10-3E5D-4D99-9BE6-8BE6229E4E13"
$newColumnName="Extension"
-Connect-SPOCSOM -Username $uss -AdminPassword $pasworde -Url "https://tenant.sharepoint.com/sites/powie3"
+Connect-SPOCSOM -Username $uss -AdminPassword $pasword -Url "https://tenant.sharepoint.com/sites/powie3"
```
+
+Enjoy and please share feedback!
\ No newline at end of file
diff --git a/Lists and Libraries Management/Column Management/Remove list column/description.md b/Lists and Libraries Management/Column Management/Remove list column/description.md
index 2b7c7368..4cbb4242 100644
--- a/Lists and Libraries Management/Column Management/Remove list column/description.md
+++ b/Lists and Libraries Management/Column Management/Remove list column/description.md
@@ -1,24 +1,15 @@
Short Powershell script removes a column from a SharePoint Online list
-
-
-
-
-
-
-Requirements
+### Requirements
Before running the script, you have to modify the last lines!
-
-
-
-PowerShell
+```PowerShell
Add-Type -Path "c:\Program Files\Common Files\microsoft shared\Web Server Extensions\15\ISAPI\Microsoft.SharePoint.Client.dll"
Add-Type -Path "c:\Program Files\Common Files\microsoft shared\Web Server Extensions\15\ISAPI\Microsoft.SharePoint.Client.Runtime.dll"
@@ -27,7 +18,7 @@ Add-Type -Path "c:\Program Files\Common Files\microsoft shared\Web Server Extens
Remove-SPOListColumn -Username user@domain.onmicrosoft.com -Url https://tenant.sharepoint.com/sites/teamsitewithlists -AdminPassword Pass -ListTitle "contacts list" -FieldTitle "ool"
-
+```
Enter your credentials
FieldTitle means the name of the column that you want to delete
@@ -36,13 +27,17 @@ Verify if the SharePoint Online SDK is installed in the same location on your co
-
-
-
-Related scripts:
+### Related scripts
Create a new column using Powershell cmdlet
https://gallery.technet.microsoft.com/scriptcenter/Create-a-new-column-for-a-501108c6
Create a new choice column and define choices using Powershell cmdlet
https://gallery.technet.microsoft.com/scriptcenter/Create-a-new-choice-column-34d957d8
+
+
+
+
+
+
+Enjoy and please share feedback!
diff --git a/Lists and Libraries Management/Copy folder structure across SharePoint Online sites/description.md b/Lists and Libraries Management/Copy folder structure across SharePoint Online sites/description.md
index 03e13349..fc6b0e2d 100644
--- a/Lists and Libraries Management/Copy folder structure across SharePoint Online sites/description.md
+++ b/Lists and Libraries Management/Copy folder structure across SharePoint Online sites/description.md
@@ -38,7 +38,7 @@ For all the data please stick to the formats as in the example.
-Technicalities
+## Technicalities
The scripts works with libraries, not lists.
@@ -46,8 +46,13 @@ I tested it with several scenarios and it worked. However, testing went only as
-Error handling
+## Error handling
Upper/lower case shouldn't cause any issues. That means whether you enter "DocLibrary" or "docliBRARY" they should be treated the same. If you notice otherwise, please report.
Folders keep their casing. That means that "Big InvestMent" will remain "Big InvestMent" in the new library.
+
+
+
+
+Enjoy and please share feedback!
\ No newline at end of file
diff --git a/Lists and Libraries Management/Copy folder structure across SharePoint Online tenants/description.md b/Lists and Libraries Management/Copy folder structure across SharePoint Online tenants/description.md
index 6c4d78d4..6847c937 100644
--- a/Lists and Libraries Management/Copy folder structure across SharePoint Online tenants/description.md
+++ b/Lists and Libraries Management/Copy folder structure across SharePoint Online tenants/description.md
@@ -2,13 +2,13 @@ A script to copy folder structure from a library in one tenant to a library in a
-How to use?
+## How to use?
1. Download the script and open the file (you can use Powershell ISE or e.g. NotePad).
2. Edit the following lines, entering your values (# means comment, changing these lines won't bring any effect):
-PowerShell
+```PowerShell
# Enter the username of a user who has enough permissions to read the source site
$admin1="t@trial890.onmicrosoft.com"
@@ -22,14 +22,14 @@ $destLibr="try1"
# Enter the username of a user who has enough permissions to create folders in the target site
$admin2="t@trial900.onmicrosoft.com"
-
-$admin1 - user who has enough permissions to read the source site
-$admin2 - user who has enough permissions to create folders in the target site
-$Sourcesite - url of the site where the source library is; it's the url of the site where you want to copy FROM
-$destinationSite - url of the site where the target library is; it's the url of the site where you want to copy TO
-$sourceLibrary - title of the original library where you want to copy the structure FROM
+```
+```$admin1``` - user who has enough permissions to read the source site
+```$admin2``` - user who has enough permissions to create folders in the target site
+```$Sourcesite``` - url of the site where the source library is; it's the url of the site where you want to copy FROM
+```$destinationSite``` - url of the site where the target library is; it's the url of the site where you want to copy TO
+```$sourceLibrary``` - title of the original library where you want to copy the structure FROM
-$destLibr - title of the destination library where you want to copy the structure TO
+```$destLibr``` - title of the destination library where you want to copy the structure TO
For all the data please stick to the formats as in the example.
@@ -39,7 +39,7 @@ For all the data please stick to the formats as in the example.
-Technicalities
+## Technicalities
The scripts works with libraries, not lists.
@@ -47,7 +47,7 @@ I tested it with several scenarios and it worked. However, testing went only as
-Error handling
+## Error handling
Upper/lower case shouldn't cause any issues. That means whether you enter "DocLibrary" or "docliBRARY" they should be treated the same. If you notice otherwise, please report.
@@ -55,7 +55,7 @@ Folders keep their casing. That means that "Big InvestMent" will remain "Big Inv
-Other migration solutions
+## Other migration solutions
Copy folder structure across SharePoint Online sites
@@ -63,3 +63,5 @@ Copy folder structure from one library to another (SharePoint Online)
+
+Enjoy and please share feedback!
\ No newline at end of file
diff --git a/Lists and Libraries Management/Copy folder structure from one library to another (SharePoint Online) 2/description.md b/Lists and Libraries Management/Copy folder structure from one library to another (SharePoint Online) 2/description.md
index 0e51f5a4..b3f505c2 100644
--- a/Lists and Libraries Management/Copy folder structure from one library to another (SharePoint Online) 2/description.md
+++ b/Lists and Libraries Management/Copy folder structure from one library to another (SharePoint Online) 2/description.md
@@ -34,13 +34,7 @@ $destLibr - title of the destination library where you want to copy the structur
3. Save and run the script. During execution it will ask you for a password.
-
-
-
-
-
-
### Technicalities
@@ -48,8 +42,11 @@ The scripts works with libraries, not lists.
-
-
### Error handling
There isn't any. Make sure you enter the names correctly.
+
+
+
+
+Enjoy and please share feedback!
\ No newline at end of file
diff --git a/Lists and Libraries Management/Copy folder structure from one library to another/description.md b/Lists and Libraries Management/Copy folder structure from one library to another/description.md
index 21ffbbe0..e1350862 100644
--- a/Lists and Libraries Management/Copy folder structure from one library to another/description.md
+++ b/Lists and Libraries Management/Copy folder structure from one library to another/description.md
@@ -28,14 +28,14 @@ $destLibr - title of the destination library where you want to copy the structur
3. Save and run the script. During execution it will ask you for a password.
-
-
-
-
-
### Technicalities
The scripts works with libraries, not lists.
+
+
+
+
+Enjoy and please share feedback!
\ No newline at end of file
diff --git a/Lists and Libraries Management/Create SPO list with a Powershell cmdlet/description.md b/Lists and Libraries Management/Create SPO list with a Powershell cmdlet/description.md
index 0acca281..2ded46fe 100644
--- a/Lists and Libraries Management/Create SPO list with a Powershell cmdlet/description.md
+++ b/Lists and Libraries Management/Create SPO list with a Powershell cmdlet/description.md
@@ -32,7 +32,7 @@ Adds a list to an existing site
-Parameters
+## Parameters
The cmdlet is using the following parameters:
@@ -69,7 +69,7 @@ Optional. Sets the url of the list. If not specified, the url will be the same a
-Examples
+## Examples
@@ -123,7 +123,7 @@ Creating list with a url different from the title & more examples
-Requirements
+## Requirements
@@ -133,13 +133,14 @@ The following libraries (SharePoint Online SDK) are required. If those libraries
-PowerShell
+```PowerShell
# Paths to SDK. Please verify location on your computer.
Add-Type -Path "c:\Program Files\Common Files\microsoft shared\Web Server Extensions\15\ISAPI\Microsoft.SharePoint.Client.dll"
Add-Type -Path "c:\Program Files\Common Files\microsoft shared\Web Server Extensions\15\ISAPI\Microsoft.SharePoint.Client.Runtime.dll"
-
+```
-Let me know about your experience in the Q&A section!
+
+Enjoy and please share feedback!
diff --git a/Lists and Libraries Management/Create a new choice column/description.md b/Lists and Libraries Management/Create a new choice column/description.md
index d47c9484..e65a94f4 100644
--- a/Lists and Libraries Management/Create a new choice column/description.md
+++ b/Lists and Libraries Management/Create a new choice column/description.md
@@ -1,6 +1,6 @@
Powershell module with a new cmdlet
-New-SPOListChoiceColumn
+```New-SPOListChoiceColumn```
@@ -10,95 +10,86 @@ Import the module to make the cmdlet available.
-Parameters
+## Parameters
The cmdlet is using the following parameters:
- [string]$Username
+``` [string]$Username```
The string specifies admin of the site
-[string]$Url
+```[string]$Url```
Specifies the url of a site where you have the list
-[string]$AdminPassword,
+```[string]$AdminPassword```
Admin's password
-[string]$ListTitle
+```[string]$ListTitle```
Specifies the title of the list where you want to change the settings.
-[string]$FieldDisplayName
+```[string]$FieldDisplayName```
Mandatory
-[String[]] $ChoiceNames,
+```[String[]] $ChoiceNames```
Choices that you want to add as options for users to choose. Add each choice after a comma - you can add as many as you like.
e.g. -ChoiceNames choice1, choice2, option3, option5, option100
-[string]$Description=""
+```[string]$Description=""```
Optional.
-[string]$Required="false"
+```[string]$Required="false"```
Optional. Specifies whether the field is required.
-[ValidateSet('Dropdown','Radiobuttons', 'Checkboxes')] [string]$Format="Dropdown",
+```[ValidateSet('Dropdown','Radiobuttons', 'Checkboxes')] [string]$Format="Dropdown"```
Optional. Specifies the format of the field. By default set to "dropdown"
-[string]$Group=""
+```[string]$Group=""```
Optional.
-[string]$StaticName
+```[string]$StaticName```
Mandatory
-[string]$Name
+```[string]$Name```
Mandatory
-[string]$Version="1"
+```[string]$Version="1"```
Optional.
-Examples
-
-
+## Examples
+```PowerShell
New-SPOListChoiceColumn -Username -Url https://tenant.sharepoint.com/sites/teamsitewithlists -AdminPassword Pass -ListTitle "Contacts list" -FieldDisplayName elp -Description "desdes"-Required true -ChoiceNames bio, ewe, ewe, ewewe
-
+```
-
-
+
-
Results:
-
-
+
-
-
-
-
-
-
-Requirements
+## Requirements
The following libraries (SharePoint Online SDK) are required. If those libraries are in different location on your computer, please edit the .psm1 file!
-PowerShell
+```PowerShell
# Paths to SDK. Please verify location on your computer.
Add-Type -Path "c:\Program Files\Common Files\microsoft shared\Web Server Extensions\15\ISAPI\Microsoft.SharePoint.Client.dll"
Add-Type -Path "c:\Program Files\Common Files\microsoft shared\Web Server Extensions\15\ISAPI\Microsoft.SharePoint.Client.Runtime.dll"
-
-Let me know about your experience in the Q&A section!
-
+```
-
+
+
+
+Enjoy and please share feedback!
\ No newline at end of file
diff --git a/Lists and Libraries Management/Create a new column in list/description.md b/Lists and Libraries Management/Create a new column in list/description.md
index 2cbbe921..adfa5865 100644
--- a/Lists and Libraries Management/Create a new column in list/description.md
+++ b/Lists and Libraries Management/Create a new column in list/description.md
@@ -10,7 +10,7 @@ Import the module using import-module and use the cmdlet whenever you want!
-Parameters
+## Parameters
The cmdlet is using the following parameters:
@@ -60,7 +60,7 @@ Examples
-Requirements
+## Requirements
The following libraries (SharePoint Online SDK) are required. If those libraries are in different location on your computer, please edit the .psm1 file!
@@ -68,15 +68,17 @@ The following libraries (SharePoint Online SDK) are required. If those libraries
-PowerShell
+```PowerShell
# Paths to SDK. Please verify location on your computer.
Add-Type -Path "c:\Program Files\Common Files\microsoft shared\Web Server Extensions\15\ISAPI\Microsoft.SharePoint.Client.dll"
Add-Type -Path "c:\Program Files\Common Files\microsoft shared\Web Server Extensions\15\ISAPI\Microsoft.SharePoint.Client.Runtime.dll"
-
+```
-Let me know about your experience in the Q&A section!
-
+
+Enjoy and please share feedback!
+
+
\ No newline at end of file
diff --git a/Lists and Libraries Management/Create new column with properties/description.md b/Lists and Libraries Management/Create new column with properties/description.md
index 2baf85c8..52d098a4 100644
--- a/Lists and Libraries Management/Create new column with properties/description.md
+++ b/Lists and Libraries Management/Create new column with properties/description.md
@@ -10,7 +10,7 @@ New-SPOListColumnWithProperties
-Parameters
+## Parameters
The cmdlet is using the following parameters:
@@ -59,7 +59,7 @@ Optional.
-Requirements
+## Requirements
The following libraries (SharePoint Online SDK) are required. If those libraries are in different location on your computer, please edit the .psm1 file!
@@ -67,10 +67,13 @@ The following libraries (SharePoint Online SDK) are required. If those libraries
-PowerShell
+```PowerShell
# Paths to SDK. Please verify location on your computer.
Add-Type -Path "c:\Program Files\Common Files\microsoft shared\Web Server Extensions\15\ISAPI\Microsoft.SharePoint.Client.dll"
Add-Type -Path "c:\Program Files\Common Files\microsoft shared\Web Server Extensions\15\ISAPI\Microsoft.SharePoint.Client.Runtime.dll"
-
+```
+
+
+Enjoy and please share feedback!
diff --git a/Lists and Libraries Management/Delete unique permissions for all lists in a site collection/description.md b/Lists and Libraries Management/Delete unique permissions for all lists in a site collection/description.md
index 70ea0b5d..1d97db08 100644
--- a/Lists and Libraries Management/Delete unique permissions for all lists in a site collection/description.md
+++ b/Lists and Libraries Management/Delete unique permissions for all lists in a site collection/description.md
@@ -8,7 +8,7 @@ Before you run it, you have to modify the last line of the script!
-PowerShell
+```PowerShell
# Paths to SDK. Please verify location on your computer.
Add-Type -Path "c:\Program Files\Common Files\microsoft shared\Web Server Extensions\15\ISAPI\Microsoft.SharePoint.Client.dll"
Add-Type -Path "c:\Program Files\Common Files\microsoft shared\Web Server Extensions\15\ISAPI\Microsoft.SharePoint.Client.Runtime.dll"
@@ -16,7 +16,7 @@ Add-Type -Path "c:\Program Files\Common Files\microsoft shared\Web Server Extens
Set-SPOListResetRoleInheritance -Username "trial@trialtrial123.onmicrosoft.com" -Url "https://trialtrial123.sharepoint.com" -AdminPassword "Pass" -IncludeSubsites $true
-
+```
Enter your credentials and the site where you want to modify the inheritance.
Set -IncludeSubsites $true if you want to restore inherited permissions also in the subsites
@@ -26,7 +26,7 @@ Verify if the SharePoint Online SDK is installed in the same location on your co
-Related scripts:
+## Related scripts
Break inheritance for all lists
@@ -37,3 +37,8 @@ Modify list permissions with Powershell cmdlets (module)
Delete unique permissions (C# program)
Get lists with unique permissions (C# program)
+
+
+
+
+Enjoy and please share feedback!
\ No newline at end of file
diff --git a/Lists and Libraries Management/GetSPOList Module to view and filter SPO list properties/description.md b/Lists and Libraries Management/GetSPOList Module to view and filter SPO list properties/description.md
index a5988876..39a3d750 100644
--- a/Lists and Libraries Management/GetSPOList Module to view and filter SPO list properties/description.md
+++ b/Lists and Libraries Management/GetSPOList Module to view and filter SPO list properties/description.md
@@ -155,5 +155,5 @@ If you don't load the properties, you cannot search by them!
-
-Let me know about your experience in the Q&A section!
+
+Enjoy and please share feedback!
diff --git a/Lists and Libraries Management/GetSPOListCount cmdlet/description.md b/Lists and Libraries Management/GetSPOListCount cmdlet/description.md
index 0d06b5ac..42c21901 100644
--- a/Lists and Libraries Management/GetSPOListCount cmdlet/description.md
+++ b/Lists and Libraries Management/GetSPOListCount cmdlet/description.md
@@ -92,8 +92,8 @@ You get the count for all sites and subsite + the error for public site.
-
-Let me know about your experience in the Q&A section!
+
+Enjoy and please share feedback!
diff --git a/Lists and Libraries Management/MultipleListsC#/description.txt b/Lists and Libraries Management/MultipleListsC#/description.md
similarity index 94%
rename from Lists and Libraries Management/MultipleListsC#/description.txt
rename to Lists and Libraries Management/MultipleListsC#/description.md
index cc695c51..c85662b8 100644
--- a/Lists and Libraries Management/MultipleListsC#/description.txt
+++ b/Lists and Libraries Management/MultipleListsC#/description.md
@@ -1,39 +1,45 @@
-Zip contains an .exe file which runs a program to add a list to a specified SharePoint site collection. You can choose the list template from among:
-
-contact list
-
-announcement list
-
-task list
-
-event list
-
-
-
-You can choose the number of items. Each list is created individually with different columns and different data. The data which populates the list comes from a Random() function. Some of the fields, however, intentionally have the same values to let you test filtering in your SharePoint Online tenant.
-
-The program is meant mainly for testing purposes, e.g.
-
-- creating a test environment for your company
-
-- recreating big data and a lot of items without resorting to Excel and QuickEdit
-
-- troubleshooting issues which occur when your users added more than 5000 items and you don't want or can't test on the real data
-
-
-
-As it runs, it will inform you on the percentage of its progress.
-
-
-
-Error handling:
-
-There is no error handling in this tool. It is designed for admins who know what to do with them.
-
-
-
-Expected errors:
-
-The lists are named after the number of elements they include so be careful not to create another one with the same number on the same site collection - you will get an error!
-
-SPO has an unchangeable view limit for lists and it is 5000 elements. With this tool you can go way above the SharePoint limit of 5000 items (tested with 17 000), so if you decide to create a list with 40 000 elements, expect some issues there. For your convenience, I created a default view for announcements list with 70 items limit. You can easily switch between the views in the GUI.
+Zip contains an .exe file which runs a program to add a list to a specified SharePoint site collection. You can choose the list template from among:
+
+contact list
+
+announcement list
+
+task list
+
+event list
+
+
+
+You can choose the number of items. Each list is created individually with different columns and different data. The data which populates the list comes from a Random() function. Some of the fields, however, intentionally have the same values to let you test filtering in your SharePoint Online tenant.
+
+The program is meant mainly for testing purposes, e.g.
+
+- creating a test environment for your company
+
+- recreating big data and a lot of items without resorting to Excel and QuickEdit
+
+- troubleshooting issues which occur when your users added more than 5000 items and you don't want or can't test on the real data
+
+
+
+As it runs, it will inform you on the percentage of its progress.
+
+
+
+Error handling:
+
+There is no error handling in this tool. It is designed for admins who know what to do with them.
+
+
+
+Expected errors:
+
+The lists are named after the number of elements they include so be careful not to create another one with the same number on the same site collection - you will get an error!
+
+SPO has an unchangeable view limit for lists and it is 5000 elements. With this tool you can go way above the SharePoint limit of 5000 items (tested with 17 000), so if you decide to create a list with 40 000 elements, expect some issues there. For your convenience, I created a default view for announcements list with 70 items limit. You can easily switch between the views in the GUI.
+
+
+
+
+
+Enjoy and please share feedback!
\ No newline at end of file
diff --git a/Lists and Libraries Management/Powershell Module for Managing SPO Lists/description.txt b/Lists and Libraries Management/Powershell Module for Managing SPO Lists/description.md
similarity index 93%
rename from Lists and Libraries Management/Powershell Module for Managing SPO Lists/description.txt
rename to Lists and Libraries Management/Powershell Module for Managing SPO Lists/description.md
index 235ec8a6..e6ceeffe 100644
--- a/Lists and Libraries Management/Powershell Module for Managing SPO Lists/description.txt
+++ b/Lists and Libraries Management/Powershell Module for Managing SPO Lists/description.md
@@ -1,141 +1,116 @@
-SharePoint Online Powershell module including several cmdlets useful for SharePoint Online lists and libraries management.
-
-The cmdlets allow you to set several settings available under Library/List Settings on the portal:
-
-
-
-
-
-The Cmdlets
-
-
-
-Remove-ListInheritance
-
-Remove-SPOList
-
-Restore-ListInheritance
-
-Set-ListCheckout
-
-Set-ListContentTypesEnabled
-
-Set-ListFolderCreationEnabled
-
-Set-ListIRMEnabled
-
-Set-ListMinorVersioning
-
-Set-ListVersioning
-
-
-
-
-
-The cmdlets are using common parameters:
-
- [string]$Username
-The string specifies admin of the site
-
-[string]$Url
-Specifies the url of a site where you have the list
-
-[string]$AdminPassword,
-Admin's password
-
-[bool]$Enabled=$true
-Specifies whether the setting should be enabled ($true) or disabled ($false)
-
-[string]$ListName
-Specifies the title of the list where you want to change the settings.
-
-
-
-
-
-Requirements
-
-
-
-The following libraries (SharePoint Online SDK) are required. If those libraries are in different location on your computer, please edit the .psm1 file!
-
-
-
-
-
-PowerShell
-# Paths to SDK. Please verify location on your computer.
-Add-Type -Path "c:\Program Files\Common Files\microsoft shared\Web Server Extensions\15\ISAPI\Microsoft.SharePoint.Client.dll"
-Add-Type -Path "c:\Program Files\Common Files\microsoft shared\Web Server Extensions\15\ISAPI\Microsoft.SharePoint.Client.Runtime.dll"
-
-
-
-
-
-
-
-Examples
-
-
-
-PS C:\Windows\system32> Import-Module d:\Powershell\SetListFunctions5.psm1 -Verbose
-
-VERBOSE: Loading module from path 'D:\Powershell\SetListFunctions5.psm1'.
-
-VERBOSE: Importing function 'Remove-ListInheritance'.
-
-VERBOSE: Importing function 'Remove-SPOList'.
-
-VERBOSE: Importing function 'Restore-ListInheritance'.
-
-VERBOSE: Importing function 'Set-ListCheckout'.
-
-VERBOSE: Importing function 'Set-ListContentTypesEnabled'.
-
-VERBOSE: Importing function 'Set-ListFolderCreationEnabled'.
-
-VERBOSE: Importing function 'Set-ListIRMEnabled'.
-
-VERBOSE: Importing function 'Set-ListMinorVersioning'.
-
-VERBOSE: Importing function 'Set-ListVersioning'.
-
-PS C:\Windows\system32> Remove-SPOList -Username admin@trialtrial123.onmicrosoft.com -Url https://trialtrial123.sharepoint.com -ListName docc -AdminPassword Password
-
-Done!
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-Let me know about your experience in the Q&A section!
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
+SharePoint Online Powershell module including several cmdlets useful for SharePoint Online lists and libraries management.
+
+The cmdlets allow you to set several settings available under Library/List Settings on the portal:
+
+
+
+
+
+The Cmdlets
+
+
+
+Remove-ListInheritance
+
+Remove-SPOList
+
+Restore-ListInheritance
+
+Set-ListCheckout
+
+Set-ListContentTypesEnabled
+
+Set-ListFolderCreationEnabled
+
+Set-ListIRMEnabled
+
+Set-ListMinorVersioning
+
+Set-ListVersioning
+
+
+
+
+
+The cmdlets are using common parameters:
+
+ [string]$Username
+The string specifies admin of the site
+
+[string]$Url
+Specifies the url of a site where you have the list
+
+[string]$AdminPassword,
+Admin's password
+
+[bool]$Enabled=$true
+Specifies whether the setting should be enabled ($true) or disabled ($false)
+
+[string]$ListName
+Specifies the title of the list where you want to change the settings.
+
+
+
+
+
+Requirements
+
+
+
+The following libraries (SharePoint Online SDK) are required. If those libraries are in different location on your computer, please edit the .psm1 file!
+
+
+
+
+
+PowerShell
+# Paths to SDK. Please verify location on your computer.
+Add-Type -Path "c:\Program Files\Common Files\microsoft shared\Web Server Extensions\15\ISAPI\Microsoft.SharePoint.Client.dll"
+Add-Type -Path "c:\Program Files\Common Files\microsoft shared\Web Server Extensions\15\ISAPI\Microsoft.SharePoint.Client.Runtime.dll"
+
+
+
+
+
+
+
+Examples
+
+
+
+PS C:\Windows\system32> Import-Module d:\Powershell\SetListFunctions5.psm1 -Verbose
+
+VERBOSE: Loading module from path 'D:\Powershell\SetListFunctions5.psm1'.
+
+VERBOSE: Importing function 'Remove-ListInheritance'.
+
+VERBOSE: Importing function 'Remove-SPOList'.
+
+VERBOSE: Importing function 'Restore-ListInheritance'.
+
+VERBOSE: Importing function 'Set-ListCheckout'.
+
+VERBOSE: Importing function 'Set-ListContentTypesEnabled'.
+
+VERBOSE: Importing function 'Set-ListFolderCreationEnabled'.
+
+VERBOSE: Importing function 'Set-ListIRMEnabled'.
+
+VERBOSE: Importing function 'Set-ListMinorVersioning'.
+
+VERBOSE: Importing function 'Set-ListVersioning'.
+
+PS C:\Windows\system32> Remove-SPOList -Username admin@trialtrial123.onmicrosoft.com -Url https://trialtrial123.sharepoint.com -ListName docc -AdminPassword Password
+
+Done!
+
+
+
+
+
+
+
+
+Enjoy and please share feedback!
+
+
diff --git a/Lists and Libraries Management/Set all lists to New or Classic Experience/Capture465.PNG b/Lists and Libraries Management/Set all lists to New or Classic Experience/Capture465.PNG
new file mode 100644
index 00000000..c7dc92b5
Binary files /dev/null and b/Lists and Libraries Management/Set all lists to New or Classic Experience/Capture465.PNG differ
diff --git a/Lists and Libraries Management/Set all lists to New or Classic Experience/Capture466.PNG b/Lists and Libraries Management/Set all lists to New or Classic Experience/Capture466.PNG
new file mode 100644
index 00000000..251c0439
Binary files /dev/null and b/Lists and Libraries Management/Set all lists to New or Classic Experience/Capture466.PNG differ
diff --git a/Lists and Libraries Management/Set all lists to New or Classic Experience/SetExperience.ps1 b/Lists and Libraries Management/Set all lists to New or Classic Experience/SetExperience.ps1
new file mode 100644
index 00000000..f929ceef
--- /dev/null
+++ b/Lists and Libraries Management/Set all lists to New or Classic Experience/SetExperience.ps1
@@ -0,0 +1,64 @@
+function Set-ExperienceOptions
+{
+param (
+ [Parameter(Mandatory=$true,Position=1)]
+ [string]$Username,
+ [Parameter(Mandatory=$true,Position=2)]
+ [string]$Url,
+ [Parameter(Mandatory=$true,Position=3)]
+ $password,
+[Parameter(Mandatory=$true, Position=4)]
+[ValidateSet("NewExperience", "ClassicExperience","Auto")]
+$ExperienceOption
+ )
+
+
+ $ctx=New-Object Microsoft.SharePoint.Client.ClientContext($url)
+ $ctx.Credentials = New-Object Microsoft.SharePoint.Client.SharePointOnlineCredentials($Username, $password)
+ $ctx.Load($ctx.Web)
+ $ctx.ExecuteQuery()
+ $lls=$ctx.Web.Lists
+ $ctx.Load($lls)
+ $ctx.ExecuteQuery()
+
+
+ foreach($ll in $lls)
+ {
+
+ $ll.ListExperienceOptions = $ExperienceOption
+ $ll.Update()
+ $ctx.ExecuteQuery()
+ }
+
+
+
+
+
+
+
+ }
+
+
+
+
+
+
+
+
+
+#Paths to SDK
+Add-Type -Path "H:\Libraries\Microsoft.SharePoint.Client.dll"
+Add-Type -Path "H:\Libraries\Microsoft.SharePoint.Client.Runtime.dll"
+Add-Type -Path "H:\Libraries\Microsoft.Office.Client.Policy.dll"
+#Add-Type -Path "c:\Program Files\Common Files\microsoft shared\Web Server Extensions\16\ISAPI\Microsoft.SharePoint.Client.Runtime.dll"
+
+
+#Enter the data
+$AdminPassword=Read-Host -Prompt "Enter password" -AsSecureString
+$username="t@testova365.onmicrosoft.com"
+$Url="https://testova365.sharepoint.com/sites/STS"
+
+
+
+
+Set-ExperienceOptions -Username $username -Url $Url -password $AdminPassword -ExperienceOption NewExperience
\ No newline at end of file
diff --git a/Lists and Libraries Management/Set all lists to New or Classic Experience/description.md b/Lists and Libraries Management/Set all lists to New or Classic Experience/description.md
new file mode 100644
index 00000000..3a4f720c
--- /dev/null
+++ b/Lists and Libraries Management/Set all lists to New or Classic Experience/description.md
@@ -0,0 +1,33 @@
+Short Powershell that sets all lists to a chosen look: ClassicExperience (old UI), NewExperience (modern look) or Auto Setting.
+
+
+
+Old UI (ClassicExperience):
+
+
+
+Modern UI (NewExperience):
+
+
+
+
+
+
+
+
+
+In order to run the script, download, open the file and edit the 2 lines below:
+
+```PowerShell
+$username="t@testova365.onmicrosoft.com"
+$Url="https://testova365.sharepoint.com/sites/STS"
+```
+Choose the experience you want to set for your lists:
+NewExperience - modern UI
+ClassicExperience - old UI
+Auto
+PowerShell
+Set-ExperienceOptions -Username $username -Url $Url -password $AdminPassword -ExperienceOption NewExperience
+
+The script loops through ALL existing lists on the site and updates ALL of them (including default and hidden lists).
+
diff --git a/Lists and Libraries Management/Set the direction of the reading order/For All Lists/description.md b/Lists and Libraries Management/Set the direction of the reading order/For All Lists/description.md
index 02151523..a31c7b61 100644
--- a/Lists and Libraries Management/Set the direction of the reading order/For All Lists/description.md
+++ b/Lists and Libraries Management/Set the direction of the reading order/For All Lists/description.md
@@ -24,7 +24,7 @@ You have to enter the list information before running the script:
-PowerShell
+```PowerShell
# Paths to SDK. Please verify location on your computer.
Add-Type -Path "c:\Program Files\Common Files\microsoft shared\Web Server Extensions\15\ISAPI\Microsoft.SharePoint.Client.dll"
Add-Type -Path "c:\Program Files\Common Files\microsoft shared\Web Server Extensions\15\ISAPI\Microsoft.SharePoint.Client.Runtime.dll"
@@ -34,7 +34,7 @@ $Username="trial@trialtrial123.onmicrosoft.com"
$AdminPassword="Pass"
$Url="https://trialtrial123.sharepoint.com/sites/teamsitewithlists"
$Direction="rtl"
-
+```
@@ -42,10 +42,12 @@ $Direction="rtl"
Results:
-
+
+
+Enjoy and please share feedback!
Related scripts
Set direction of the reading order for a single list
diff --git a/Lists and Libraries Management/Set the direction of the reading order/For a single list/description.md b/Lists and Libraries Management/Set the direction of the reading order/For a single list/description.md
index 0bb8faef..bc32c240 100644
--- a/Lists and Libraries Management/Set the direction of the reading order/For a single list/description.md
+++ b/Lists and Libraries Management/Set the direction of the reading order/For a single list/description.md
@@ -24,7 +24,7 @@ You have to enter the list information before running the script:
-PowerShell
+```PowerShell
# Paths to SDK. Please verify location on your computer.
Add-Type -Path "c:\Program Files\Common Files\microsoft shared\Web Server Extensions\15\ISAPI\Microsoft.SharePoint.Client.dll"
Add-Type -Path "c:\Program Files\Common Files\microsoft shared\Web Server Extensions\15\ISAPI\Microsoft.SharePoint.Client.Runtime.dll"
@@ -36,12 +36,14 @@ $Url="https://trialtrial123.sharepoint.com/sites/teamsitewithlists"
$ListName="Generic List"
$Direction ="none"
$Direction paramater specifies the reading order. Enter "ltr", "rtl" or "none"
-
+```
+
+Enjoy and please share feedback!
Related scripts
diff --git a/Lists and Libraries Management/Verify which lists have the new UI using Powershell and REST/GetExperienceWithREST.ps1 b/Lists and Libraries Management/Verify which lists have the new UI using Powershell and REST/GetExperienceWithREST.ps1
new file mode 100644
index 00000000..67ed824d
--- /dev/null
+++ b/Lists and Libraries Management/Verify which lists have the new UI using Powershell and REST/GetExperienceWithREST.ps1
@@ -0,0 +1,64 @@
+function Get-ExperienceOptions
+{
+param (
+ [Parameter(Mandatory=$true,Position=1)]
+ [string]$Username,
+ [Parameter(Mandatory=$true,Position=2)]
+ $password,
+ [Parameter(Mandatory=$true,Position=3)]
+ [string] $url
+ )
+
+
+
+ $Credentials = New-Object Microsoft.SharePoint.Client.SharePointOnlineCredentials($Username, $password)
+ $RestUrl=$url+"/_api/web/lists"
+
+
+
+ $request = [System.Net.WebRequest]::Create($RESTUrl)
+ $request.Credentials = $Credentials
+ $request.Headers.Add("X-FORMS_BASED_AUTH_ACCEPTED", "f")
+ $request.Accept = "application/json;odata=verbose"
+ [Microsoft.PowerShell.Commands.WebRequestMethod]$Method = [Microsoft.PowerShell.Commands.WebRequestMethod]::Get
+ $request.Method=$Method
+ $response = $request.GetResponse()
+ $requestStream = $response.GetResponseStream()
+ $read = New-Object System.IO.StreamReader $requestStream
+ $data=$read.ReadToEnd()
+ $results = $data | ConvertFrom-Json
+ $listy=$results.d.results
+
+
+ foreach($ll in $listy)
+ {
+
+ $obj = New-Object PSObject
+ $obj | Add-Member NoteProperty "Title" ($ll.Title) -Force
+ $obj | Add-Member NoteProperty "Experience" ($ll.ListExperienceOptions) -Force
+ Write-Output ($obj)
+ }
+
+
+
+
+
+
+
+ }
+
+
+
+
+
+
+
+#Enter the data
+$AdminPassword=Read-Host -Prompt "Enter password" -AsSecureString
+$username="t@testova365.onmicrosoft.com"
+$Url="https://testova365.sharepoint.com/sites/STS"
+
+
+
+
+Get-ExperienceOptions -Username $username -Url $Url -password $AdminPassword
\ No newline at end of file
diff --git a/Lists and Libraries Management/Verify which lists have the new UI using Powershell and REST/description.md b/Lists and Libraries Management/Verify which lists have the new UI using Powershell and REST/description.md
new file mode 100644
index 00000000..8f8acc05
--- /dev/null
+++ b/Lists and Libraries Management/Verify which lists have the new UI using Powershell and REST/description.md
@@ -0,0 +1,49 @@
+Short Powershell that checks which SharePoint Online list has what experience setting.
+
+
+
+Old UI (ClassicExperience):
+
+
+
+Modern UI (NewExperience):
+
+
+
+
+
+
+
+
+
+In order to run the script, download, open the file and edit the 2 lines below:
+
+
+
+PowerShell
+$username="t@testova365.onmicrosoft.com"
+$Url="https://testova365.sharepoint.com/sites/STS"
+The script loops through ALL existing lists on the site (including default and hidden lists).
+
+
+Expected results:
+
+
+
+
+
+ 1 - NewExperience
+
+2 - Classic Experience
+
+0 - Auto
+
+
+
+You can also export the results to a .csv file:
+
+
+
+PowerShell
+E:\technet\ListExperiences\GetExperienceWithREST.ps1 | export-csv c:\ListExperiences.csv
+
diff --git a/Lists and Libraries Management/Verify which lists have the new UI using Powershell and REST/images/Capture471.PNG b/Lists and Libraries Management/Verify which lists have the new UI using Powershell and REST/images/Capture471.PNG
new file mode 100644
index 00000000..c7dc92b5
Binary files /dev/null and b/Lists and Libraries Management/Verify which lists have the new UI using Powershell and REST/images/Capture471.PNG differ
diff --git a/Lists and Libraries Management/Verify which lists have the new UI using Powershell and REST/images/Capture472.PNG b/Lists and Libraries Management/Verify which lists have the new UI using Powershell and REST/images/Capture472.PNG
new file mode 100644
index 00000000..251c0439
Binary files /dev/null and b/Lists and Libraries Management/Verify which lists have the new UI using Powershell and REST/images/Capture472.PNG differ
diff --git a/Lists and Libraries Management/Verify which lists have the new UI using Powershell and REST/images/Capture473.PNG b/Lists and Libraries Management/Verify which lists have the new UI using Powershell and REST/images/Capture473.PNG
new file mode 100644
index 00000000..d84dfaf8
Binary files /dev/null and b/Lists and Libraries Management/Verify which lists have the new UI using Powershell and REST/images/Capture473.PNG differ
diff --git a/Lists and Libraries Management/Verify which lists have the new UI using Powershell and REST/images/test.txt b/Lists and Libraries Management/Verify which lists have the new UI using Powershell and REST/images/test.txt
new file mode 100644
index 00000000..9c558e35
--- /dev/null
+++ b/Lists and Libraries Management/Verify which lists have the new UI using Powershell and REST/images/test.txt
@@ -0,0 +1 @@
+.
diff --git a/Lists and Libraries Management/Verify which lists have the new UI/GetExperience (1).ps1 b/Lists and Libraries Management/Verify which lists have the new UI/GetExperience (1).ps1
new file mode 100644
index 00000000..24afdee2
--- /dev/null
+++ b/Lists and Libraries Management/Verify which lists have the new UI/GetExperience (1).ps1
@@ -0,0 +1,62 @@
+function Get-ExperienceOptions
+{
+param (
+ [Parameter(Mandatory=$true,Position=1)]
+ [string]$Username,
+ [Parameter(Mandatory=$true,Position=2)]
+ [string]$Url,
+ [Parameter(Mandatory=$true,Position=3)]
+ $password
+ )
+
+
+ $ctx=New-Object Microsoft.SharePoint.Client.ClientContext($url)
+ $ctx.Credentials = New-Object Microsoft.SharePoint.Client.SharePointOnlineCredentials($Username, $password)
+ $ctx.Load($ctx.Web)
+ $ctx.ExecuteQuery()
+ $lls=$ctx.Web.Lists
+ $ctx.Load($lls)
+ $ctx.ExecuteQuery()
+
+
+ foreach($ll in $lls)
+ {
+
+ $obj = New-Object PSObject
+ $obj | Add-Member NoteProperty "Title" ($ll.Title) -Force
+ $obj | Add-Member NoteProperty "Experience" ($ll.ListExperienceOptions) -Force
+ Write-Output ($obj)
+ }
+
+
+
+
+
+
+
+ }
+
+
+
+
+
+
+
+
+
+#Paths to SDK
+Add-Type -Path "H:\Libraries\Microsoft.SharePoint.Client.dll"
+Add-Type -Path "H:\Libraries\Microsoft.SharePoint.Client.Runtime.dll"
+Add-Type -Path "H:\Libraries\Microsoft.Office.Client.Policy.dll"
+#Add-Type -Path "c:\Program Files\Common Files\microsoft shared\Web Server Extensions\16\ISAPI\Microsoft.SharePoint.Client.Runtime.dll"
+
+
+#Enter the data
+$AdminPassword=Read-Host -Prompt "Enter password" -AsSecureString
+$username="t@testova365.onmicrosoft.com"
+$Url="https://testova365.sharepoint.com/sites/STS"
+
+
+
+
+Get-ExperienceOptions -Username $username -Url $Url -password $AdminPassword
\ No newline at end of file
diff --git a/Lists and Libraries Management/Verify which lists have the new UI/description.md b/Lists and Libraries Management/Verify which lists have the new UI/description.md
new file mode 100644
index 00000000..970a0ee3
--- /dev/null
+++ b/Lists and Libraries Management/Verify which lists have the new UI/description.md
@@ -0,0 +1,60 @@
+Short Powershell that checks which SharePoint Online list has what experience setting.
+
+
+
+Old UI (ClassicExperience):
+
+
+
+Modern UI (NewExperience):
+
+
+
+
+
+
+
+
+
+In order to run the script, download, open the file and edit the 2 lines below:
+
+
+
+PowerShell
+$username="t@testova365.onmicrosoft.com"
+$Url="https://testova365.sharepoint.com/sites/STS"
+The script loops through ALL existing lists on the site (including default and hidden lists).
+
+
+Expected results:
+
+
+
+
+
+
+
+
+
+You can also export the results to a .csv file:
+
+
+
+PowerShell
+E:\technet\ListExperiences\GetExperience.ps1 | export-csv c:\ListExperiences.csv
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
diff --git a/Lists and Libraries Management/Verify which lists have the new UI/images/Capture435.PNG b/Lists and Libraries Management/Verify which lists have the new UI/images/Capture435.PNG
new file mode 100644
index 00000000..c7dc92b5
Binary files /dev/null and b/Lists and Libraries Management/Verify which lists have the new UI/images/Capture435.PNG differ
diff --git a/Lists and Libraries Management/Verify which lists have the new UI/images/Capture436.PNG b/Lists and Libraries Management/Verify which lists have the new UI/images/Capture436.PNG
new file mode 100644
index 00000000..251c0439
Binary files /dev/null and b/Lists and Libraries Management/Verify which lists have the new UI/images/Capture436.PNG differ
diff --git a/Lists and Libraries Management/Verify which lists have the new UI/images/Capture437.PNG b/Lists and Libraries Management/Verify which lists have the new UI/images/Capture437.PNG
new file mode 100644
index 00000000..65713322
Binary files /dev/null and b/Lists and Libraries Management/Verify which lists have the new UI/images/Capture437.PNG differ
diff --git a/Lists and Libraries Management/Verify which lists have the new UI/images/Capture438.PNG b/Lists and Libraries Management/Verify which lists have the new UI/images/Capture438.PNG
new file mode 100644
index 00000000..bc291808
Binary files /dev/null and b/Lists and Libraries Management/Verify which lists have the new UI/images/Capture438.PNG differ
diff --git a/Lists and Libraries Management/Verify which lists have the new UI/images/test.txt b/Lists and Libraries Management/Verify which lists have the new UI/images/test.txt
new file mode 100644
index 00000000..8b137891
--- /dev/null
+++ b/Lists and Libraries Management/Verify which lists have the new UI/images/test.txt
@@ -0,0 +1 @@
+
diff --git a/Lists and Libraries Management/Versioning/Create a report on all file versions in the library/description.md b/Lists and Libraries Management/Versioning/Create a report on all file versions in the library/description.md
index fa7182f8..a54ece0f 100644
--- a/Lists and Libraries Management/Versioning/Create a report on all file versions in the library/description.md
+++ b/Lists and Libraries Management/Versioning/Create a report on all file versions in the library/description.md
@@ -14,7 +14,7 @@ You have to enter the library data before running the script:
-PowerShell
+```PowerShell
#Paths to SDK
Add-Type -Path "c:\Program Files\Common Files\microsoft shared\Web Server Extensions\15\ISAPI\Microsoft.SharePoint.Client.dll"
Add-Type -Path "c:\Program Files\Common Files\microsoft shared\Web Server Extensions\15\ISAPI\Microsoft.SharePoint.Client.Runtime.dll"
@@ -28,7 +28,7 @@ $csvPath="C:\Users\ivo\Desktop\testpath4.csv"
$csvPath2="C:\Users\ivo\Desktop\FileThatShowNoVersionsAvailable4.csv"
Get-sPOFolderFiles -Username $username -Url $Url -password $AdminPassword -ListTitle $ListTitle -CSVPath $csvPath -CSVPath2 $csvPath2
-
+```
$Url specifies the url of the site with the library
@@ -41,17 +41,14 @@ The report generates 2 files. One - the main file - with all versions available.
-Sample Report:
-
-
+### Sample Report
+
-
-
-Related scripts:
+### Related scripts
Create a report on file versions
@@ -62,4 +59,5 @@ Create a report on file versions
-
+
+Enjoy and please share feedback!
diff --git a/Lists and Libraries Management/Versioning/Create a report on file versions in library or folder/description.md b/Lists and Libraries Management/Versioning/Create a report on file versions in library or folder/description.md
index 22c191c1..b1e66db0 100644
--- a/Lists and Libraries Management/Versioning/Create a report on file versions in library or folder/description.md
+++ b/Lists and Libraries Management/Versioning/Create a report on file versions in library or folder/description.md
@@ -2,9 +2,6 @@ Powershell script that generates a report on available file versions in one Shar
-
-
-
It requires installed SharePoint Online SDK
@@ -12,7 +9,7 @@ You have to enter the library data before running the script:
-PowerShell
+```PowerShell
#Paths to SDK
Add-Type -Path "c:\Program Files\Common Files\microsoft shared\Web Server Extensions\15\ISAPI\Microsoft.SharePoint.Client.dll"
Add-Type -Path "c:\Program Files\Common Files\microsoft shared\Web Server Extensions\15\ISAPI\Microsoft.SharePoint.Client.Runtime.dll"
@@ -24,7 +21,7 @@ $Url="https://trialtrial125.sharepoint.com/sites/teamsitewithlibraries"
$FolderUrl="/sites/TeamsiteWithLibraries/Not-Empty-Document-Library"
$csvPath="C:\Users\ivo\Desktop\testpath.csv"
$csvPath2="C:\Users\ivo\Desktop\FileThatShowNoVersionsAvailable.csv"
-
+```
$FolderUrl in the example is a root folder. If you need to retrieve files from any other folder, you need to add /FolderName, e.g.
"/sites/TeamsiteWithLibraries/Not-Empty-Document-Library/MySampleFolder"
@@ -37,12 +34,13 @@ The report generates 2 files. One - the main file - with all versions available.
-Sample report:
+## Sample report
-
-
+
-
+
+
+Enjoy and please share feedback!
diff --git a/Lists and Libraries Management/Versioning/Delete all previous file versions in a library/description.md b/Lists and Libraries Management/Versioning/Delete all previous file versions in a library/description.md
index 1ca25f85..05beb519 100644
--- a/Lists and Libraries Management/Versioning/Delete all previous file versions in a library/description.md
+++ b/Lists and Libraries Management/Versioning/Delete all previous file versions in a library/description.md
@@ -20,7 +20,7 @@ You have to enter the library data before running the script:
-PowerShell
+```PowerShell
#Paths to SDK
Add-Type -Path "c:\Program Files\Common Files\microsoft shared\Web Server Extensions\15\ISAPI\Microsoft.SharePoint.Client.dll"
Add-Type -Path "c:\Program Files\Common Files\microsoft shared\Web Server Extensions\15\ISAPI\Microsoft.SharePoint.Client.Runtime.dll"
@@ -31,6 +31,7 @@ $username="trial@trialtrial125.onmicrosoft.com"
$Url="https://trialtrial125.sharepoint.com/sites/teamsitewithlibraries"
$ListTitle="Not-Empty-Document-Library"
$csvPath="C:\Users\ivo\Desktop\testpath114.csv"
+```
$Url specifies the url of the site with the library
@@ -41,21 +42,14 @@ The script will generate a report that states whether any versions were found an
-Sample report:
-
-
+### Sample report
+
-
-
-
-
-
-
-Related scripts:
+### Related scripts
Create a report on file versions
@@ -66,6 +60,6 @@ Create a report on all file versions in the library
-
+
+Enjoy and please share feedback!
-Please share your feedback in the Q&A section!
diff --git a/Lists and Libraries Management/Versioning/Enable minor and major versions for all lists in one site/description.md b/Lists and Libraries Management/Versioning/Enable minor and major versions for all lists in one site/description.md
index 7e11b54c..9aeb00bd 100644
--- a/Lists and Libraries Management/Versioning/Enable minor and major versions for all lists in one site/description.md
+++ b/Lists and Libraries Management/Versioning/Enable minor and major versions for all lists in one site/description.md
@@ -10,7 +10,7 @@ It requires installed SharePoint Online SDK
You have to enter the site data before running the script:
-PowerShell
+```PowerShell
# Paths to SDK. Please verify location on your computer.
Add-Type -Path "c:\Program Files\Common Files\microsoft shared\Web Server Extensions\15\ISAPI\Microsoft.SharePoint.Client.dll"
Add-Type -Path "c:\Program Files\Common Files\microsoft shared\Web Server Extensions\15\ISAPI\Microsoft.SharePoint.Client.Runtime.dll"
@@ -20,8 +20,8 @@ $Username="trial@trialtrial125.onmicrosoft.com"
$AdminPassword=Read-Host -Prompt "Enter password" -AsSecureString
$Url="https://trialtrial125.sharepoint.com/sites/teamsitewithlibraries"
$Versioning=$true
-
-Minor versions are avilable for libraries mainly, so trying to enable it in a list will throw an error (behavoiur by design)
+```
+Minor versions are avilable for libraries mainly, so trying to enable it in a list will throw an error (behaviour by design)
@@ -34,7 +34,7 @@ Full description of the script is available in the article Versioning and Share
-Related scripts
+## Related scripts
Enable versioning for all lists in one site
@@ -50,3 +50,9 @@ SharePoint Module for lists, items and files
Disable versioning for all lists in SharePoint Online tenant (C#)
Enable versioning for all lists in SharePoint Online tenant (C#)
+
+
+
+
+
+Enjoy and please share feedback!
\ No newline at end of file
diff --git a/Lists and Libraries Management/Versioning/Enable minor versions using Powershell and CSOM/description.md b/Lists and Libraries Management/Versioning/Enable minor versions using Powershell and CSOM/description.md
index db8743bf..741f330f 100644
--- a/Lists and Libraries Management/Versioning/Enable minor versions using Powershell and CSOM/description.md
+++ b/Lists and Libraries Management/Versioning/Enable minor versions using Powershell and CSOM/description.md
@@ -10,7 +10,7 @@ You have to enter the library data before running the script:
-PowerShell
+```PowerShell
# Paths to SDK. Please verify location on your computer.
Add-Type -Path "c:\Program Files\Common Files\microsoft shared\Web Server Extensions\15\ISAPI\Microsoft.SharePoint.Client.dll"
Add-Type -Path "c:\Program Files\Common Files\microsoft shared\Web Server Extensions\15\ISAPI\Microsoft.SharePoint.Client.Runtime.dll"
@@ -21,7 +21,7 @@ $username="trial@trialtrial125.onmicrosoft.com"
$Url="https://trialtrial125.sharepoint.com/sites/teamsitewithlibraries"
$ListTitle="Not-Empty-Document-Library"
$Versioning=$true
-
+```
Full description of the script is available in the article Versioning and SharePoint: the Powershell perspective
@@ -30,7 +30,7 @@ Full description of the script is available in the article Versioning and Share
-Related scripts
+## Related scripts
Enable minor versions for all SharePoint Online lists using Powershell
@@ -44,3 +44,8 @@ SharePoint Module for lists, items and files
Disable versioning for all lists in SharePoint Online tenant (C#)
Enable versioning for all lists in SharePoint Online tenant (C#)
+
+
+
+
+Enjoy and please share feedback!
\ No newline at end of file
diff --git a/Lists and Libraries Management/Versioning/Enable versioning for all lists in one site/description.md b/Lists and Libraries Management/Versioning/Enable versioning for all lists in one site/description.md
index 8f7ae675..6112dfbf 100644
--- a/Lists and Libraries Management/Versioning/Enable versioning for all lists in one site/description.md
+++ b/Lists and Libraries Management/Versioning/Enable versioning for all lists in one site/description.md
@@ -10,7 +10,7 @@ You have to enter the library/list data before running the script:
-PowerShell
+```PowerShell
# Paths to SDK. Please verify location on your computer.
Add-Type -Path "c:\Program Files\Common Files\microsoft shared\Web Server Extensions\15\ISAPI\Microsoft.SharePoint.Client.dll"
Add-Type -Path "c:\Program Files\Common Files\microsoft shared\Web Server Extensions\15\ISAPI\Microsoft.SharePoint.Client.Runtime.dll"
@@ -20,7 +20,7 @@ $Username="trial@trialtrial123.onmicrosoft.com"
$AdminPassword=Read-Host -Prompt "Enter password" -AsSecureString
$Url="https://trialtrial123.sharepoint.com/sites/teamsitewithlists"
$Versioning=$true
-
+```
Full description of the script is available in the article Versioning and SharePoint: the Powershell perspective
@@ -29,7 +29,7 @@ Full description of the script is available in the article Versioning and Share
-Related scripts
+## Related scripts
Enable minor versions for all SharePoint Online lists using Powershell
@@ -45,3 +45,5 @@ Disable versioning for all lists in SharePoint Online tenant (C#)
Enable versioning for all lists in SharePoint Online tenant (C#)
+
+Enjoy and please share feedback!
\ No newline at end of file
diff --git a/Lists and Libraries Management/Versioning/Enable versioning for one list/description.md b/Lists and Libraries Management/Versioning/Enable versioning for one list/description.md
index 5108cc71..83f59aca 100644
--- a/Lists and Libraries Management/Versioning/Enable versioning for one list/description.md
+++ b/Lists and Libraries Management/Versioning/Enable versioning for one list/description.md
@@ -10,14 +10,14 @@ You have to enter the library/list data before running the script:
-PowerShell
+```PowerShell
# Insert the credentials and the name of the site and list
$AdminPassword=Read-Host -Prompt "Enter password" -AsSecureString
$username="trial@trialtrial125.onmicrosoft.com"
$Url="https://trialtrial125.sharepoint.com/sites/teamsitewithlibraries"
$ListTitle="Not-Empty-Document-Library"
$Versioning=$true
-
+```
@@ -28,7 +28,7 @@ Full description of the script is available in the article Versioning and Share
-Related scripts
+## Related scripts
Enable minor versions for all SharePoint Online lists using Powershell
@@ -42,3 +42,8 @@ SharePoint Module for lists, items and files
Disable versioning for all lists in SharePoint Online tenant (C#)
Enable versioning for all lists in SharePoint Online tenant (C#)
+
+
+
+
+Enjoy and please share feedback!
\ No newline at end of file
diff --git a/OTHER/Remove a single event receiver/description.md b/OTHER/Remove a single event receiver/description.md
index e347ba4c..d5f18710 100644
--- a/OTHER/Remove a single event receiver/description.md
+++ b/OTHER/Remove a single event receiver/description.md
@@ -8,7 +8,7 @@ A short solution to remove a single event receiver from your SPO lists.
3. Scroll down to these lines
-PowerShell
+```PowerShell
# Paths to SDK. Please verify location on your computer.
Add-Type -Path "c:\Program Files\Common Files\microsoft shared\Web Server Extensions\15\ISAPI\Microsoft.SharePoint.Client.dll"
Add-Type -Path "c:\Program Files\Common Files\microsoft shared\Web Server Extensions\15\ISAPI\Microsoft.SharePoint.Client.Runtime.dll"
@@ -21,6 +21,7 @@ $ListTitle="kriiv"
$EventReceiverGUID="154d2ca2-8335-464c-9059-214cdcc1c2c1"
Get-SPOListEventreceivers -Username $Username -AdminPassword $AdminPassword -Url $Url -ListTitle $ListTitle -EventReceiverGUID $EventreceiverGUID
+```
4. Check if the 2 libraries are in the same location on your computer. If yes, proceed on. If no, change the paths in the file. Usually you will be required to change folder name "15" into "16".
5. Instead of admin@tenant.onmicrosoft.com, enter the name of your site collection admin.
diff --git a/OneDrive for Business/Enable versioning for all lists in OneDrive sites/Capture204.PNG b/OneDrive for Business/Enable versioning for all lists in OneDrive sites/Capture204.PNG
new file mode 100644
index 00000000..3b613cd6
Binary files /dev/null and b/OneDrive for Business/Enable versioning for all lists in OneDrive sites/Capture204.PNG differ
diff --git a/OneDrive for Business/Enable versioning for all lists in OneDrive sites/Enable versioning in ODB lists.ps1 b/OneDrive for Business/Enable versioning for all lists in OneDrive sites/Enable versioning in ODB lists.ps1
new file mode 100644
index 00000000..eb9532c5
--- /dev/null
+++ b/OneDrive for Business/Enable versioning for all lists in OneDrive sites/Enable versioning in ODB lists.ps1
@@ -0,0 +1,93 @@
+function Set-SPOListVersioning($EnableVersioning, $Urelek)
+{
+ $ctx=New-Object Microsoft.SharePoint.Client.ClientContext($urelek)
+ $ctx.Credentials = New-Object Microsoft.SharePoint.Client.SharePointOnlineCredentials($username, $Adminpassword)
+ $ctx.Load($ctx.Web.Lists)
+ $ctx.Load($ctx.Web)
+ $ctx.Load($ctx.Web.Webs)
+ $ctx.ExecuteQuery()
+ Write-Host
+ Write-Host $ctx.Url -BackgroundColor White -ForegroundColor DarkGreen
+ foreach( $ll in $ctx.Web.Lists)
+ {
+ $ll.EnableVersioning = $EnableVersioning
+ $ll.Update()
+ $csvvalue= new-object PSObject
+ $listurl=$null
+ if($ctx.Url.EndsWith("/")) {$listurl= $ctx.Url+$ll.Title}
+ else {$listurl=$ctx.Url+"/"+$ll.Title}
+ $csvvalue | Add-Member -MemberType NoteProperty -Name "Url" -Value ($listurl)
+ $csvvalue | Add-Member -MemberType NoteProperty -Name "Status" -Value "Failed"
+ try
+ {
+ $ErrorActionPreference="Stop"
+ $ctx.ExecuteQuery()
+ Write-Host $listurl -ForegroundColor DarkGreen
+ $csvvalue.Status="Success"
+ $Global:csv+= $csvvalue
+ }
+
+ catch
+ {
+ $Global:csv+= $csvvalue
+ Write-Host $listurl -ForegroundColor Red
+ }
+ finally
+ {$ErrorActionPreference="Continue"}
+
+
+ }
+
+ if($ctx.Web.Webs.Count -gt 0)
+ {
+ for($i=0; $i -lt $ctx.Web.Webs.Count ; $i++)
+ {
+ Set-SPOListVersioning -EnableVersioning $EnableVersioning -Urelek ($ctx.Web.Webs[$i].Url)
+ }
+
+ }
+
+
+
+}
+
+
+
+
+
+
+ # Paths to SDK. Please verify location on your computer.
+Add-Type -Path "c:\Windows\Microsoft.NET\assembly\GAC_MSIL\Microsoft.SharePoint.Client\v4.0_16.0.0.0__71e9bce111e9429c\Microsoft.SharePoint.Client.dll"
+Add-Type -Path "c:\Windows\Microsoft.NET\assembly\GAC_MSIL\Microsoft.SharePoint.Client.Runtime\v4.0_16.0.0.0__71e9bce111e9429c\Microsoft.SharePoint.Client.Runtime.dll"
+
+# Insert the credentials and the name of the admin site
+$Username="t@trial765.onmicrosoft.com"
+$AdminPassword=Read-Host -Prompt "Password" -AsSecureString
+Connect-SPOService https://trial765-admin.sharepoint.com -Credential $Username
+$myhost="https://trial765-my.sharepoint.com"
+
+# If you do not want to target all users, enter the target user names in the line below instead of Get-SPOUser cmdlet:
+$users=get-SPOUser -Site $myhost
+$EnableVersioning=$true
+$Global:csv=@()
+
+foreach($user in $users)
+{
+
+
+ if($user.LoginName.Contains('@'))
+ {
+ $persweb=$user.LoginName.Replace(".","_").Replace("@","_")
+ $persweb=$myhost+"/personal/"+$persweb
+ Write-Host $persweb
+
+ $AdminUrl=$persweb
+
+ #Add the following line if you want to assign yourself, administrator or another user access to other users' personal sites
+ #Set-SPOUser -Site $AdminUrl -IsSiteCollectionAdmin $true -LoginName t@trial765.onmicrosoft.com
+ Set-SPOListVersioning -EnableVersioning $EnableVersioning -Urelek $AdminUrl
+ }
+}
+
+# Specify the path where the log file will be published
+$Global:csv | Export-Csv -Path C:\Users\Public\Versioning.csv
\ No newline at end of file
diff --git a/OneDrive for Business/Enable versioning for all lists in OneDrive sites/description.md b/OneDrive for Business/Enable versioning for all lists in OneDrive sites/description.md
new file mode 100644
index 00000000..59cc0a80
--- /dev/null
+++ b/OneDrive for Business/Enable versioning for all lists in OneDrive sites/description.md
@@ -0,0 +1,26 @@
+Powershell script that enables versioning for all the libraries and lists in all personal sites (OneDrive for Business).
+
+It requires SharePoint Online Management Shell and SharePoint SDK installed:
+
+http://technet.microsoft.com/en-us/library/fp161372(v=office.15).aspx
+
+http://www.microsoft.com/en-us/download/details.aspx?id=30722
+
+
+
+It uses recurrence to find all sites in all site collections and then goes through all the lists.
+
+For some lists, enabling version may not be possible and you will receive a notification of that.
+
+At the end, a csv file is generated with the lists' urls and the status whether enabling was successful or not.
+
+
+
+As the script runs you will see green lists' titles for which the enabling succeeded and red for those which failed (not all lists support versioning).
+
+
+
+
+You can customize the script by using the commented out tips.
+
+
diff --git a/Permissions/C#/Break Inheritance for all items in site/description.md b/Permissions/C#/Break Inheritance for all items in site/description.md
new file mode 100644
index 00000000..e69de29b
diff --git a/Permissions/C#/Delete all unique permissions in site/description.md b/Permissions/C#/Delete all unique permissions in site/description.md
new file mode 100644
index 00000000..e69de29b
diff --git a/Permissions/C#/Get Items with Unique Permissions in site collection/description.md b/Permissions/C#/Get Items with Unique Permissions in site collection/description.md
new file mode 100644
index 00000000..e69de29b
diff --git a/Permissions/C#/Get Lists with Unique Permissions/description.md b/Permissions/C#/Get Lists with Unique Permissions/description.md
new file mode 100644
index 00000000..e69de29b
diff --git a/Permissions/Powershell/Get items with unique permissions SharePoint Server/Capture211.PNG b/Permissions/Powershell/Get items with unique permissions SharePoint Server/Capture211.PNG
new file mode 100644
index 00000000..17c53f39
Binary files /dev/null and b/Permissions/Powershell/Get items with unique permissions SharePoint Server/Capture211.PNG differ
diff --git a/Permissions/Powershell/Get items with unique permissions SharePoint Server/OnlyUnique.ps1 b/Permissions/Powershell/Get items with unique permissions SharePoint Server/OnlyUnique.ps1
new file mode 100644
index 00000000..2369152f
--- /dev/null
+++ b/Permissions/Powershell/Get items with unique permissions SharePoint Server/OnlyUnique.ps1
@@ -0,0 +1,33 @@
+$webUrl="Enter here the url of your site, e.g. https://intra.Company.com"
+$pathToExportReport="c:\MyCSV.csv"
+
+Add-PSSnapin Microsoft.SharePoint.PowerShell
+
+$web=Get-SPWeb $webUrl
+
+$lists=$web.Lists
+
+foreach($list in $lists)
+{
+ Write-Host "Processing list "$list.Title
+ Write-Host " ........... Items count: " $list.ItemCount
+ $items=$list.Items
+ $uniqueItemsCount=0
+ foreach($item in $items)
+ {
+
+
+ if($item.HasUniqueRoleAssignments)
+ {
+
+ $item | export-csv $pathToExportReport -Append
+ $uniqueItemsCount++
+
+ }
+
+ }
+ Write-Host " ........... Unique items count: " $uniqueItemsCount
+
+
+
+}
diff --git a/Permissions/Powershell/Get items with unique permissions SharePoint Server/description.md b/Permissions/Powershell/Get items with unique permissions SharePoint Server/description.md
new file mode 100644
index 00000000..dce547cc
--- /dev/null
+++ b/Permissions/Powershell/Get items with unique permissions SharePoint Server/description.md
@@ -0,0 +1,25 @@
+Short script to get the number of items with unique permissions per list. The scripts loops through all the lists in a single web and finds items with unique permissions. The items and their properties also get exported to a csv file.
+
+
+
+
+
+
+
+Before running the script, you need to open the file and enter correct information:
+
+
+
+```PowerShell
+$webUrl="Enter here the url of your site, e.g. https://intra.Company.com"
+$pathToExportReport="c:\MyCSV.csv"
+```
+
+
+End results:
+
+
+
+
+
+The script requires SharePoint Management Shell.
diff --git a/Permissions/Powershell/Get items, folders, lists with unique permissions (SharePoint Server 2013-2016)/Capture209.PNG b/Permissions/Powershell/Get items, folders, lists with unique permissions (SharePoint Server 2013-2016)/Capture209.PNG
new file mode 100644
index 00000000..73e6848c
Binary files /dev/null and b/Permissions/Powershell/Get items, folders, lists with unique permissions (SharePoint Server 2013-2016)/Capture209.PNG differ
diff --git a/Permissions/Powershell/Get items, folders, lists with unique permissions (SharePoint Server 2013-2016)/OnlyUniqueFLI.ps1 b/Permissions/Powershell/Get items, folders, lists with unique permissions (SharePoint Server 2013-2016)/OnlyUniqueFLI.ps1
new file mode 100644
index 00000000..c5a1a50d
--- /dev/null
+++ b/Permissions/Powershell/Get items, folders, lists with unique permissions (SharePoint Server 2013-2016)/OnlyUniqueFLI.ps1
@@ -0,0 +1,50 @@
+
+$webUrl="http://nicename:17007/sites/devSite"
+$pathToExportReport="c:\MyCSV.csv"
+
+Add-PSSnapin Microsoft.SharePoint.PowerShell
+
+$web=Get-SPWeb $webUrl
+
+$lists=$web.Lists
+
+foreach($list in $lists)
+{
+ Write-Host "Processing list "$list.Title
+ Write-Host " .... List has unique permissions: " $list.HasUniqueRoleAssignments
+ Write-Host " ........... Items count: " $list.ItemCount
+ Write-Host " ........... Folders count: " $list.Folders.Count
+
+ $folders=$list.Folders
+ $uniqueFolders=0
+ foreach($folder in $folders)
+ {
+ if($folder.HasUniqueRoleAssignments)
+ {
+ $folder | Export-Csv $pathToExportReport -Append
+ $uniqueFolders++
+ }
+
+ }
+
+
+ $items=$list.Items
+ $uniqueItemsCount=0
+ foreach($item in $items)
+ {
+
+
+ if($item.HasUniqueRoleAssignments)
+ {
+
+ $item | export-csv $pathToExportReport -Append
+ $uniqueItemsCount++
+
+ }
+
+ }
+ Write-Host " ........... Unique items count: " $uniqueItemsCount
+ Write-Host " ........... Unique folders count: " $uniqueFolders
+
+
+}
diff --git a/Permissions/Powershell/Get items, folders, lists with unique permissions (SharePoint Server 2013-2016)/description.md b/Permissions/Powershell/Get items, folders, lists with unique permissions (SharePoint Server 2013-2016)/description.md
new file mode 100644
index 00000000..6f3174c7
--- /dev/null
+++ b/Permissions/Powershell/Get items, folders, lists with unique permissions (SharePoint Server 2013-2016)/description.md
@@ -0,0 +1,25 @@
+Short script to get the number of items and folders with unique permissions per list. The scripts loops through all the lists in a single web and displays whether the list has unique permissions, the number of folders with unique permissions and the number of items with unique permissions. The items, folders, and their properties also get exported to a csv file.
+
+
+
+
+
+
+
+Before running the script, you need to open the file and enter correct information:
+
+```PowerShell
+$webUrl="Enter here the url of your site, e.g. https://intra.Company.com"
+$pathToExportReport="c:\MyCSV.csv"
+```
+
+
+End result:
+
+
+
+
+
+
+
+The script requires SharePoint Management Shell.
diff --git a/Permissions/Powershell/Remove permission groups from personal files/description.md b/Permissions/Powershell/Remove permission groups from personal files/description.md
index 55fcf030..91b0f3d5 100644
--- a/Permissions/Powershell/Remove permission groups from personal files/description.md
+++ b/Permissions/Powershell/Remove permission groups from personal files/description.md
@@ -17,9 +17,9 @@ The following script requires SharePoint Online SDK.
If the location exists and you can see
-Microsoft.SharePoint.Client.dll and
+```Microsoft.SharePoint.Client.dll``` and
-Microsoft.SharePoint.Client.Runtime.dll
+```Microsoft.SharePoint.Client.Runtime.dll```
Skip the next step and go to Step 3.
diff --git a/Remove SPO subsite/Remove SPO subsite.ps1 b/Remove SPO subsite/Remove SPO subsite.ps1
deleted file mode 100644
index 6854e7d0..00000000
--- a/Remove SPO subsite/Remove SPO subsite.ps1
+++ /dev/null
@@ -1,65 +0,0 @@
-function GetAllSubsitesAndDelete($urelek)
-{
- $ctx2 = New-Object Microsoft.SharePoint.Client.ClientContext($urelek)
-$ctx2.Credentials= New-Object Microsoft.SharePoint.Client.SharePointOnlineCredentials($username, $password)
-$rootWeb2 = $ctx2.Web
-$sites2 = $rootWeb2.Webs
-
-$ctx2.Load($rootWeb2)
-$ctx2.Load($sites2)
-$ctx2.ExecuteQuery()
-if($sites2.Count -gt 0)
- {
- for($i=0;$i -lt $sites2.Count ;$i++)
- {
- GetAllSubsitesAndDelete($sites2[$i].Url)
- }
- try
- {
- $rootWeb2.DeleteObject()
- $ctx2.ExecuteQuery()
- Write-Host "Subsite " $rootWeb2.Url " has been removed"
- }
- catch [Net.WebException]
- {
- Write-Host $_.Exception.ToString()
- }
- }
- else
- {
- try
- {
- $rootWeb2.DeleteObject()
- $ctx2.ExecuteQuery()
- Write-Host "Subsite " $rootWeb2.Url " has been removed"
- }
- catch [Net.WebException]
- {
- Write-Host $_.Exception.ToString()
- }
- }
-
-
-
-}
-
-#paths to SDK (copied from Victor's comment)
-$programFiles = [environment]::getfolderpath("programfiles")
-add-type -Path $programFiles'\SharePoint Online Management Shell\Microsoft.Online.SharePoint.PowerShell\Microsoft.SharePoint.Client.dll'
-add-type -Path $programFiles'\SharePoint Online Management Shell\Microsoft.Online.SharePoint.PowerShell\Microsoft.SharePoint.Client.Runtime.dll'
-
-# The following script will remove not only the subsite but all its content and sub-subsites
-$siteUrl = Read-Host -Prompt "Enter the subsite url,e.g.`r`nhttps://tenant.sharepoint.com/sites/mysitecollection/subsite/subsubsite`r`n”
-$username = Read-Host -Prompt "Enter admin@tenant.onmicrosoft.com"
-$password = Read-Host -Prompt "Enter password" -AsSecureString
-$ctx = New-Object Microsoft.SharePoint.Client.ClientContext($siteUrl)
-$ctx.Credentials= New-Object Microsoft.SharePoint.Client.SharePointOnlineCredentials($username, $password)
-$rootWeb = $ctx.Web
-$sites = $rootWeb.Webs
-
-$ctx.Load($rootWeb)
-$ctx.Load($sites)
-$ctx.ExecuteQuery()
-GetAllSubsitesAndDelete($rootWeb.Url)
-
-
diff --git a/Remove SPO subsite/description.md b/Remove SPO subsite/description.md
deleted file mode 100644
index f99d69d7..00000000
--- a/Remove SPO subsite/description.md
+++ /dev/null
@@ -1,15 +0,0 @@
-It requires SharePoint Online Management Shell and SharePoint SDK installed:
-
-http://technet.microsoft.com/en-us/library/fp161372(v=office.15).aspx
-
-http://www.microsoft.com/en-us/download/details.aspx?id=30722
-
-
-
-The script removes a single subsite from a site collection.
-
-A prerequisite for removing a subsite is to remove all its subsites (sub-subsites), so before it deletes the actual subsite, it checks for all sub-subsites in a recurring function and deletes them all. It works on different levels so you can also delete sub-sub-sub-subsite of a sub-sub-subsite.
-
-I find it often works when the subsite "refuses" to be deleted from GUI. How often?
-
-Please let me know in Q and A! For which situation you used it, whether it worked as expected and how I can make it better!
diff --git a/enablefeature.ps1 b/Site Management/Features/Enable feature/enablefeature.ps1
similarity index 100%
rename from enablefeature.ps1
rename to Site Management/Features/Enable feature/enablefeature.ps1
diff --git a/Site Management/Recycle Bin/Restore all reycle bin items across all site collections/RestoreAllRecycleBinItems.ps1 b/Site Management/Recycle Bin/Restore all reycle bin items across all site collections/RestoreAllRecycleBinItems.ps1
new file mode 100644
index 00000000..a8b65916
--- /dev/null
+++ b/Site Management/Recycle Bin/Restore all reycle bin items across all site collections/RestoreAllRecycleBinItems.ps1
@@ -0,0 +1,92 @@
+function Get-DeletedItems
+{
+param (
+ [Parameter(Mandatory=$true,Position=1)]
+ [string]$Username,
+ [Parameter(Mandatory=$true,Position=2)]
+ $AdminPassword,
+ [Parameter(Mandatory=$true,Position=3)]
+ [string]$Url
+)
+#$password = ConvertTo-SecureString -string $AdminPassword -AsPlainText -Force
+ $ctx=New-Object Microsoft.SharePoint.Client.ClientContext($Url)
+ $ctx.Credentials = New-Object Microsoft.SharePoint.Client.SharePointOnlineCredentials($Username, $AdminPassword)
+
+try
+{
+$ctx.ExecuteQuery()
+} catch [Net.WebException]
+ {
+
+ Write-Host $Url " failed to connect to the site" $_.Exception.Message.ToString() -ForegroundColor Red
+}
+
+ $ctx.Load($ctx.Site)
+ $ctx.Load($ctx.Web.Webs)
+ $rb=$ctx.Site.RecycleBin
+$ctx.Load($rb)
+try
+{
+$ctx.ExecuteQuery()
+Write-Host $ctx.Site.Url " Items in the recycle bin: " $rb.Count.ToString()
+} catch [Net.WebException]
+ {
+
+ Write-Host $ctx.Site.Url " failed" $_.Exception.Message.ToString() -ForegroundColor Red
+
+}
+
+$myarray=@()
+for($i=0;$i -lt $rb.Count ;$i++)
+{
+
+ $obj = $rb[$i]
+ $myarray+=$obj
+
+}
+
+Write-Host "Items to process: " $myarray.Count
+
+for($i=0;$i -lt $myarray.Count ; $i++){
+
+$myarray[$i].Restore()
+try{
+$ctx.ExecuteQuery()
+Write-Host $myarray[$i].LeafName " restored" -ForegroundColor Green
+}
+catch [Net.WebException]
+{
+ Write-Host $myarray[$i].LeafName " failed" $_.Message.ToString() -ForegroundColor Red
+}
+
+}
+
+
+
+
+
+}
+
+
+
+
+# Paths to SDK. Please verify location on your computer.
+Add-Type -Path "c:\Program Files\Common Files\microsoft shared\Web Server Extensions\16\ISAPI\Microsoft.SharePoint.Client.dll"
+Add-Type -Path "c:\Program Files\Common Files\microsoft shared\Web Server Extensions\16\ISAPI\Microsoft.SharePoint.Client.Runtime.dll"
+
+# Insert the credentials and the name of the admin site
+$Username="t@trial765.onmicrosoft.com"
+$AdminPassword=Read-Host -Prompt "Password" -AsSecureString
+$AdminUrl="https://trial765-admin.sharepoint.com"
+Connect-SPOService -Url $adminUrl
+$sites=(Get-SPOSite).Url
+
+foreach($site in $sites)
+{
+
+ Get-DeletedItems -Username $Username -AdminPassword $AdminPassword -Url $site
+
+}
+
+
+
diff --git a/Site Management/Recycle Bin/Restore all reycle bin items across all site collections/RestoreBasedAllSiteCollections-1.PNG b/Site Management/Recycle Bin/Restore all reycle bin items across all site collections/RestoreBasedAllSiteCollections-1.PNG
new file mode 100644
index 00000000..7e235dd8
Binary files /dev/null and b/Site Management/Recycle Bin/Restore all reycle bin items across all site collections/RestoreBasedAllSiteCollections-1.PNG differ
diff --git a/Site Management/Recycle Bin/Restore all reycle bin items across all site collections/RestoreBasedAllSiteCollections2-1.PNG b/Site Management/Recycle Bin/Restore all reycle bin items across all site collections/RestoreBasedAllSiteCollections2-1.PNG
new file mode 100644
index 00000000..69cb87f3
Binary files /dev/null and b/Site Management/Recycle Bin/Restore all reycle bin items across all site collections/RestoreBasedAllSiteCollections2-1.PNG differ
diff --git a/Site Management/Recycle Bin/Restore all reycle bin items across all site collections/description.md b/Site Management/Recycle Bin/Restore all reycle bin items across all site collections/description.md
new file mode 100644
index 00000000..ab43d2a6
--- /dev/null
+++ b/Site Management/Recycle Bin/Restore all reycle bin items across all site collections/description.md
@@ -0,0 +1,46 @@
+The script loops across all site collections in the tenant and finds all deleted items and restores them all.
+
+
+
+More variations of the script are available on Technet Gallery: https://gallery.technet.microsoft.com/office/site/search?query=recycle%20bin&f%5B1%5D.Value=recycle%20bin&f%5B1%5D.Type=SearchText&f%5B0%5D.Value=Arleta%20Wanat&f%5B0%5D.Type=User&ac=4
+
+
+
+
+
+
+
+The script will notify you as it loops through the sites if there are any items at all in the site collection recycle bin; it will restore them and print out their names in green.
+
+If it runs into any troubles (e.g. duplicate items already exist and the mysite host) it will notify you about it in red
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+Before running the script you need to open the file and enter the correct the data:
+
+
+
+```PowerShell
+# Paths to SDK. Please verify location on your computer.
+Add-Type -Path "c:\Program Files\Common Files\microsoft shared\Web Server Extensions\16\ISAPI\Microsoft.SharePoint.Client.dll"
+Add-Type -Path "c:\Program Files\Common Files\microsoft shared\Web Server Extensions\16\ISAPI\Microsoft.SharePoint.Client.Runtime.dll"
+
+# Insert the credentials and the name of the admin site
+$Username="t@trial765.onmicrosoft.com"
+$AdminPassword=Read-Host -Prompt "Password" -AsSecureString
+$AdminUrl="https://trial765-admin.sharepoint.com"
+```
+
+```$Username``` correponds to the global admin who has access to all the site collections you want to loop through.
diff --git a/Remove SPO subsite.ps1 b/Site Management/Remove SPO subsite/Remove SPO subsite.ps1
similarity index 100%
rename from Remove SPO subsite.ps1
rename to Site Management/Remove SPO subsite/Remove SPO subsite.ps1
diff --git a/Versioning/C# Disable versioning for all lists in SharePoint Online tenant/DisVersioning.rar b/Versioning/C# Disable versioning for all lists in SharePoint Online tenant/DisVersioning.rar
deleted file mode 100644
index 0597167b..00000000
Binary files a/Versioning/C# Disable versioning for all lists in SharePoint Online tenant/DisVersioning.rar and /dev/null differ
diff --git a/Versioning/C# Disable versioning for all lists in SharePoint Online tenant/description.md b/Versioning/C# Disable versioning for all lists in SharePoint Online tenant/description.md
deleted file mode 100644
index 57729ea5..00000000
--- a/Versioning/C# Disable versioning for all lists in SharePoint Online tenant/description.md
+++ /dev/null
@@ -1,9 +0,0 @@
-A short console application that disables minor and major versioning for all the libraries and lists in the whole SharePoint Online tenant.
-
-
-
-It uses recurrence to find all sites in all site collections and then goes through all the lists.
-
-At the end, the application generates a report, which enumerates all the lists for which versioning has been disabled. The report can be viewed in Excel.
-
-The code includes basic error handling and credential verification.
diff --git a/Versioning/C# Disable versioning for all lists in SharePoint Online tenant/disver.jpg b/Versioning/C# Disable versioning for all lists in SharePoint Online tenant/disver.jpg
deleted file mode 100644
index 6992cc99..00000000
Binary files a/Versioning/C# Disable versioning for all lists in SharePoint Online tenant/disver.jpg and /dev/null differ
diff --git a/Versioning/C# Disable versioning for all lists in SharePoint Online tenant/solution.cs b/Versioning/C# Disable versioning for all lists in SharePoint Online tenant/solution.cs
deleted file mode 100644
index f8b6ed9c..00000000
--- a/Versioning/C# Disable versioning for all lists in SharePoint Online tenant/solution.cs
+++ /dev/null
@@ -1,80 +0,0 @@
-static private void getall(string url)
- {
-
- ClientContext ctx = new ClientContext(url);
- ctx.Credentials = new SharePointOnlineCredentials(userName, ss);
- ctx.Load(ctx.Web);
- ctx.Load(ctx.Web.Lists);
- ctx.ExecuteQuery();
- success += "\n" + ctx.Web.Url + "\n" + Environment.NewLine;
- failed += "\n" + ctx.Web.Url + "\n";
- Console.WriteLine("\n" + ctx.Web.Url + "\n");
- foreach (List ll in ctx.Web.Lists)
- {
-
- ll.EnableVersioning = versioning;
- ll.Update();
- try
- {
- ctx.ExecuteQuery();
- success += ll.Title + "\n" + Environment.NewLine;
- Console.WriteLine("Disabled versioning for " + ll.Title);
- }
- catch (Exception e)
- {
- Console.WriteLine("Couldn't for " + ll.Title + "\n" + e.Message);
- failed += ll.Title + "\n";
- }
-
-
- }
-
-
- ctx.Load(ctx.Web.Webs);
- try
- {
- ctx.ExecuteQuery();
- }
- catch (Exception e)
- {
- Console.WriteLine("Couldn't open " + url + ".\n" + e.Message);
- }
-
-
- for (int i = 0; i < ctx.Web.Webs.Count; i++)
- {
- ctx.Load(ctx.Web.Webs[i].Lists);
- ctx.Load(ctx.Web.Webs[i].Webs);
- ctx.ExecuteQuery();
- success += "\n" + ctx.Web.Webs[i].Url + "\n";
- failed += "\n" + ctx.Web.Webs[i].Url + "\n";
- Console.WriteLine("\n" + ctx.Web.Webs[i].Url + "\n");
-
- foreach (List l in ctx.Web.Webs[i].Lists)
- {
- l.EnableVersioning = versioning;
- l.Update();
- try
- {
- ctx.ExecuteQuery();
- Console.WriteLine("Disabled versioning for " + l.Title);
- success += l.Title + "\n";
- }
- catch (Exception e)
- {
- Console.WriteLine("Couldn't disable for " + l.Title + "\n" + e.Message);
- failed += l.Title + "\n";
- }
-
- }
-
- if (ctx.Web.Webs[i].Webs.Count > 0)
- {
- Console.WriteLine("Discovered " + ctx.Web.Webs[i].Webs.Count.ToString() + " webs for " + ctx.Web.Webs[i].Url.ToString());
- for (int j = 0; j < ctx.Web.Webs[i].Webs.Count; j++)
- {
- getall(ctx.Web.Webs[i].Webs[j].Url);
- }
- }
- }
- }
diff --git a/Versioning/C# Enable versioning for all lists in SharePoint Online tenant/Versioning.rar b/Versioning/C# Enable versioning for all lists in SharePoint Online tenant/Versioning.rar
deleted file mode 100644
index 21e7bbc3..00000000
Binary files a/Versioning/C# Enable versioning for all lists in SharePoint Online tenant/Versioning.rar and /dev/null differ
diff --git a/Versioning/C# Enable versioning for all lists in SharePoint Online tenant/description.txt b/Versioning/C# Enable versioning for all lists in SharePoint Online tenant/description.txt
deleted file mode 100644
index 30bcf8d0..00000000
--- a/Versioning/C# Enable versioning for all lists in SharePoint Online tenant/description.txt
+++ /dev/null
@@ -1,11 +0,0 @@
-A short console application that enables versioning for all the libraries and lists in the whole tenant.
-
-
-
-It uses recurrence to find all sites in all site collections and then goes through all the lists.
-
-For some lists, enabling version may not be possible and you will receive a notification of that.
-
-At the end, the application generates a report, which you view in Excel.
-
-
diff --git a/Versioning/C# Enable versioning for all lists in SharePoint Online tenant/solution.cs b/Versioning/C# Enable versioning for all lists in SharePoint Online tenant/solution.cs
deleted file mode 100644
index 2c8c6408..00000000
--- a/Versioning/C# Enable versioning for all lists in SharePoint Online tenant/solution.cs
+++ /dev/null
@@ -1,129 +0,0 @@
-static void Credentials()
- {
- Console.WriteLine("\n\nPlease enter Administrator's login, e.g. admin@domain.onmicrosoft.com:");
- userName = Console.ReadLine();
- Console.WriteLine("Please enter SPO Admin site, e.g. https://domain-admin.sharepoint.com:");
- webUri = Console.ReadLine();
- if (!webUri.EndsWith("-admin.sharepoint.com") || !webUri.StartsWith("https://"))
- {
- Console.WriteLine("Didn't recognize the url. Please enter SPO Admin site again, following exactly this format: https://domain-admin.sharepoint.com");
- webUri = Console.ReadLine();
- }
- Console.WriteLine("\nEnter password: ");
- ss.Clear();
- ConsoleKeyInfo nextKey = Console.ReadKey(true);
-
- while (nextKey.Key != ConsoleKey.Enter)
- {
- if (nextKey.Key == ConsoleKey.Backspace)
- {
- if (ss.Length > 0)
- {
- ss.RemoveAt(ss.Length - 1);
- // erase the last * as well
- Console.Write(nextKey.KeyChar);
- Console.Write(" ");
- Console.Write(nextKey.KeyChar);
- }
- }
- else
- {
- ss.AppendChar(nextKey.KeyChar);
- Console.Write("*");
- }
- nextKey = Console.ReadKey(true);
- }
-
- ClientContext ctx = new ClientContext(webUri);
- ctx.Credentials = new SharePointOnlineCredentials(userName, ss);
- try
- {
- ctx.ExecuteQuery();
- }
- catch
- {
- Console.WriteLine("Couldn't authenticate. Please re-enter your credentials");
- Credentials();
- }
- }
-
- static private void getall(string url)
- {
-
- ClientContext ctx = new ClientContext(url);
- ctx.Credentials = new SharePointOnlineCredentials(userName, ss);
- ctx.Load(ctx.Web);
- ctx.Load(ctx.Web.Lists);
- ctx.ExecuteQuery();
- success += "\n" + ctx.Web.Url + "\n"+Environment.NewLine;
- failed += "\n" + ctx.Web.Url + "\n";
- Console.WriteLine("\n" + ctx.Web.Url + "\n");
- foreach (List ll in ctx.Web.Lists)
- {
-
- ll.EnableVersioning = versioning;
- ll.Update();
- try
- {
- ctx.ExecuteQuery();
- success += ll.Title + "\n"+Environment.NewLine;
- Console.WriteLine("Enabled versioning for "+ll.Title);
- }
- catch (Exception e)
- {
- Console.WriteLine("Couldn't for " + ll.Title + "\n" + e.Message);
- failed += ll.Title + "\n";
- }
-
-
- }
-
-
- ctx.Load(ctx.Web.Webs);
- try
- {
- ctx.ExecuteQuery();
- }
- catch (Exception e)
- {
- Console.WriteLine("Couldn't open " + url + ".\n" + e.Message);
- }
-
-
- for (int i = 0; i < ctx.Web.Webs.Count; i++)
- {
- ctx.Load(ctx.Web.Webs[i].Lists);
- ctx.Load(ctx.Web.Webs[i].Webs);
- ctx.ExecuteQuery();
- success += "\n" + ctx.Web.Webs[i].Url + "\n";
- failed += "\n" + ctx.Web.Webs[i].Url + "\n";
- Console.WriteLine("\n" + ctx.Web.Webs[i].Url + "\n");
-
- foreach (List l in ctx.Web.Webs[i].Lists)
- {
- l.EnableVersioning = versioning;
- l.Update();
- try
- {
- ctx.ExecuteQuery();
- Console.WriteLine("Enabled versioning for " + l.Title);
- success += l.Title + "\n";
- }
- catch(Exception e)
- {
- Console.WriteLine("Couldn't enable for " + l.Title + "\n" + e.Message);
- failed+=l.Title+"\n";
- }
-
- }
-
- if (ctx.Web.Webs[i].Webs.Count > 0)
- {
- Console.WriteLine("Discovered " + ctx.Web.Webs[i].Webs.Count.ToString() + " webs for " + ctx.Web.Webs[i].Url.ToString());
- for (int j = 0; j < ctx.Web.Webs[i].Webs.Count; j++)
- {
- getall(ctx.Web.Webs[i].Webs[j].Url);
- }
- }
- }
- }
diff --git a/Versioning/C# Enable versioning for all lists in SharePoint Online tenant/vers1.jpg b/Versioning/C# Enable versioning for all lists in SharePoint Online tenant/vers1.jpg
deleted file mode 100644
index 2107f986..00000000
Binary files a/Versioning/C# Enable versioning for all lists in SharePoint Online tenant/vers1.jpg and /dev/null differ
diff --git a/Versioning/C# Enable versioning for all lists in SharePoint Online tenant/vers3.jpg b/Versioning/C# Enable versioning for all lists in SharePoint Online tenant/vers3.jpg
deleted file mode 100644
index 7c874a91..00000000
Binary files a/Versioning/C# Enable versioning for all lists in SharePoint Online tenant/vers3.jpg and /dev/null differ
diff --git a/Versioning/C# Enable versioning for all lists in SharePoint Online tenant/vers4.jpg b/Versioning/C# Enable versioning for all lists in SharePoint Online tenant/vers4.jpg
deleted file mode 100644
index 650227dc..00000000
Binary files a/Versioning/C# Enable versioning for all lists in SharePoint Online tenant/vers4.jpg and /dev/null differ
diff --git a/Versioning/PS Enable minor versions for all lists/MinorVersioning.ps1 b/Versioning/Enable minor versions for all lists/MinorVersioning.ps1
similarity index 100%
rename from Versioning/PS Enable minor versions for all lists/MinorVersioning.ps1
rename to Versioning/Enable minor versions for all lists/MinorVersioning.ps1
diff --git a/Versioning/PS Enable minor versions for all lists/description.md b/Versioning/Enable minor versions for all lists/description.md
similarity index 100%
rename from Versioning/PS Enable minor versions for all lists/description.md
rename to Versioning/Enable minor versions for all lists/description.md
diff --git a/Versioning/PS Enable minor versions for all lists/minorversioning.png b/Versioning/Enable minor versions for all lists/minorversioning.png
similarity index 100%
rename from Versioning/PS Enable minor versions for all lists/minorversioning.png
rename to Versioning/Enable minor versions for all lists/minorversioning.png
diff --git a/Versioning/PS Enable minor versions for all lists/minorversioning2.png b/Versioning/Enable minor versions for all lists/minorversioning2.png
similarity index 100%
rename from Versioning/PS Enable minor versions for all lists/minorversioning2.png
rename to Versioning/Enable minor versions for all lists/minorversioning2.png
diff --git a/Versioning/PS Enable versioning for all SharePoint Online lists/Versioning.ps1 b/Versioning/Enable versioning for all SharePoint Online lists/Versioning.ps1
similarity index 100%
rename from Versioning/PS Enable versioning for all SharePoint Online lists/Versioning.ps1
rename to Versioning/Enable versioning for all SharePoint Online lists/Versioning.ps1
diff --git a/Versioning/Enable versioning for all SharePoint Online lists/description.md b/Versioning/Enable versioning for all SharePoint Online lists/description.md
new file mode 100644
index 00000000..72534dac
--- /dev/null
+++ b/Versioning/Enable versioning for all SharePoint Online lists/description.md
@@ -0,0 +1,31 @@
+A short script that enables versioning for all the libraries and lists in the whole tenant.
+
+It requires SharePoint Online Management Shell and SharePoint SDK installed:
+
+http://technet.microsoft.com/en-us/library/fp161372(v=office.15).aspx
+
+http://www.microsoft.com/en-us/download/details.aspx?id=30722
+
+
+
+It uses recurrence to find all sites in all site collections and then goes through all the lists.
+
+For some lists, enabling version may not be possible and you will receive a notification of that.
+
+At the end, a csv file is generated with the lists' urls and the status whether enabling was successful or not.
+
+
+
+As the script runs you will see green lists' titles for which the enabling succeeded and red for those which failed (not all lists support versioning).
+
+
+
+
+
+
+
+
+You can customize the script by using the commented out tips.
+
+
+Enjoy and please share feedback!
diff --git a/Versioning/PS Enable versioning for all SharePoint Online lists/enableversioning.ps1 b/Versioning/Enable versioning for all SharePoint Online lists/enableversioning.ps1
similarity index 96%
rename from Versioning/PS Enable versioning for all SharePoint Online lists/enableversioning.ps1
rename to Versioning/Enable versioning for all SharePoint Online lists/enableversioning.ps1
index f889535b..c744e415 100644
--- a/Versioning/PS Enable versioning for all SharePoint Online lists/enableversioning.ps1
+++ b/Versioning/Enable versioning for all SharePoint Online lists/enableversioning.ps1
@@ -60,7 +60,7 @@ $versioning = $true
# You can also enter credentials directly: $siteUrl="https://tenant-admin.sharepoint.com"
$siteUrl = Read-Host -Prompt "Enter https://tenant-admin.sharepoint.com”
-$username = Read-Host -Prompt "Enter admin's login, e.g. admin@domain.onmicrosoft.com"
+$username = Read-Host -Prompt "Enter admin login, e.g. admin@domain.onmicrosoft.com"
$password = Read-Host -Prompt "Enter password" -AsSecureString
$credy= New-Object System.Management.Automation.PSCredential($username,$password)
Connect-SPOService -Credential $credy -Url $siteUrl
diff --git a/Versioning/PS Enable versioning for all SharePoint Online lists/versioningPS.png b/Versioning/Enable versioning for all SharePoint Online lists/versioningPS.png
similarity index 100%
rename from Versioning/PS Enable versioning for all SharePoint Online lists/versioningPS.png
rename to Versioning/Enable versioning for all SharePoint Online lists/versioningPS.png
diff --git a/Versioning/PS Enable versioning for all SharePoint Online lists/versioningPS2.png b/Versioning/Enable versioning for all SharePoint Online lists/versioningPS2.png
similarity index 100%
rename from Versioning/PS Enable versioning for all SharePoint Online lists/versioningPS2.png
rename to Versioning/Enable versioning for all SharePoint Online lists/versioningPS2.png
diff --git a/Versioning/PS Enable versioning for all SharePoint Online lists/versioningPS3.png b/Versioning/Enable versioning for all SharePoint Online lists/versioningPS3.png
similarity index 100%
rename from Versioning/PS Enable versioning for all SharePoint Online lists/versioningPS3.png
rename to Versioning/Enable versioning for all SharePoint Online lists/versioningPS3.png
diff --git a/Versioning/Enable versioning for all lists in OneDrive sites/description.md b/Versioning/Enable versioning for all lists in OneDrive sites/description.md
index efa5e103..59cc0a80 100644
--- a/Versioning/Enable versioning for all lists in OneDrive sites/description.md
+++ b/Versioning/Enable versioning for all lists in OneDrive sites/description.md
@@ -17,7 +17,7 @@ At the end, a csv file is generated with the lists' urls and the status whether
As the script runs you will see green lists' titles for which the enabling succeeded and red for those which failed (not all lists support versioning).
-
+
diff --git a/Versioning/PS Enable versioning for all SharePoint Online lists/description.txt b/Versioning/PS Enable versioning for all SharePoint Online lists/description.txt
deleted file mode 100644
index fe17d31e..00000000
--- a/Versioning/PS Enable versioning for all SharePoint Online lists/description.txt
+++ /dev/null
@@ -1,52 +0,0 @@
-A short script that enables versioning for all the libraries and lists in the whole tenant.
-
-It requires SharePoint Online Management Shell and SharePoint SDK installed:
-
-http://technet.microsoft.com/en-us/library/fp161372(v=office.15).aspx
-
-http://www.microsoft.com/en-us/download/details.aspx?id=30722
-
-
-
-It uses recurrence to find all sites in all site collections and then goes through all the lists.
-
-For some lists, enabling version may not be possible and you will receive a notification of that.
-
-At the end, a csv file is generated with the lists' urls and the status whether enabling was successful or not.
-
-
-
-As the script runs you will see green lists' titles for which the enabling succeeded and red for those which failed (not all lists support versioning).
-
-Versioning will always fail for public site.
-
-
-You can customize the script by using the commented out tips:
-
-
-
-PowerShell
-# Paths to SDK. Please verify location on your computer.
-Add-Type -Path "c:\Program Files\Common Files\microsoft shared\Web Server Extensions\15\ISAPI\Microsoft.SharePoint.Client.dll"
-Add-Type -Path "c:\Program Files\Common Files\microsoft shared\Web Server Extensions\15\ISAPI\Microsoft.SharePoint.Client.Runtime.dll"
-
-# Versioning will be enabled. If you prefer to disable it for the whole tenant, change to $false
-$versioning = $true
-
-# You can also enter credentials directly: $siteUrl="https://tenant-admin.sharepoint.com"
-$siteUrl = Read-Host -Prompt "Enter https://tenant-admin.sharepoint.com”
-$username = Read-Host -Prompt "Enter admin's login, e.g. admin@domain.onmicrosoft.com"
-$password = Read-Host -Prompt "Enter password" -AsSecureString
-$credy= New-Object System.Management.Automation.PSCredential($username,$password)
-Connect-SPOService -Credential $credy -Url $siteUrl
-
-$sitecollections=get-SPOSite
-$Global:csv=@()
-
-foreach($sitecoll in $sitecollections)
-{
- getall($sitecoll.Url)
-}
-
-# Specify the path where the log file will be published
-$Global:csv | Export-Csv -Path C:\Users\Public\Versioning.csv
diff --git a/Versioning/Restore previous versions in selected files the entire library/RestorePreviousVersionsInSelectedFiles.ps1 b/Versioning/Restore previous versions in selected files the entire library/RestorePreviousVersionsInSelectedFiles.ps1
new file mode 100644
index 00000000..67a8430b
--- /dev/null
+++ b/Versioning/Restore previous versions in selected files the entire library/RestorePreviousVersionsInSelectedFiles.ps1
@@ -0,0 +1,116 @@
+function Get-SPOFolderFiles
+{
+param (
+ [Parameter(Mandatory=$true,Position=1)]
+ [string]$Username,
+ [Parameter(Mandatory=$true,Position=2)]
+ [string]$Url,
+ [Parameter(Mandatory=$true,Position=3)]
+ $password,
+ [Parameter(Mandatory=$true,Position=4)]
+ [string]$ListTitle
+ )
+
+
+ $ctx=New-Object Microsoft.SharePoint.Client.ClientContext($Url)
+ $ctx.Credentials = New-Object Microsoft.SharePoint.Client.SharePointOnlineCredentials($Username, $password)
+ $ctx.Load($ctx.Web)
+ $ctx.ExecuteQuery()
+ $ll=$ctx.Web.Lists.GetByTitle($ListTitle)
+ $ctx.Load($ll)
+ $ctx.ExecuteQuery()
+ $spqQuery = New-Object Microsoft.SharePoint.Client.CamlQuery
+ $spqQuery.ViewXml ="/VersionTest/Folder2/FolderWithinFolder";
+ $itemki=$ll.GetItems($spqQuery)
+ $ctx.Load($itemki)
+ $ctx.ExecuteQuery()
+
+ foreach($item in $itemki)
+ {
+
+
+ # Write-Host $item["FileRef"] -ForegroundColor DarkGreen
+ $file =
+ $ctx.Web.GetFileByServerRelativeUrl($item["FileRef"]);
+ $ctx.Load($file)
+ $ctx.Load($file.Versions)
+ try{
+ $ctx.ExecuteQuery() }
+ catch
+ {
+ continue;
+ }
+
+ #$file.TimeLastModified
+ $date=Get-Date ("2/12/2017")
+
+ if($file.TimeLastModified -gt $date)
+ {
+
+ Write-host $file.Name -ForegroundColor Green
+ if ($file.Versions.Count -eq 0)
+ {
+ $obj=New-Object PSObject
+ $obj | Add-Member NoteProperty ServerRelativeUrl($file.ServerRelativeUrl)
+ $obj | Add-Member NoteProperty FileLeafRef($item["FileLeafRef"])
+ $obj | Add-Member NoteProperty Versions("No Versions Available")
+
+ #$obj | export-csv -Path $CSVPath -Append
+
+ Write-Output $obj
+ }
+ elseif($file.TypedObject.ToString() -eq "Microsoft.SharePoint.Client.File")
+ {
+
+ foreach ($vv in $file.Versions){
+ Write-Host $vv.Created $vv.Size $vv.VersionLabel $vv.IsCurrentVersion $file.Versions.Count
+
+ # Write-Output $vv
+
+ }
+ if($file.Versions[($file.Versions.Count-1)].IsCurrentVersion)
+ {
+ $vLabel=$file.Versions[($file.Versions.Count-2)].VersionLabel
+ Write-Host "Version to be restored: " $vLabel
+ }
+ else{ $vLabel=$file.Versions[($file.Versions.Count-1)].VersionLabel
+ Write-Host "Version to be restored: " $vLabel }
+ $file.Versions.RestoreByLabel($vLabel)
+ $ctx.ExecuteQuery()
+ }
+
+ else
+ {
+$obj = New-Object PSObject
+$obj| Add-Member NoteProperty FileLeafRef($item["FileLeafRef"])
+ $obj | Add-Member NoteProperty Versions("No Versions Available")
+ Write-Output $obj
+ }
+
+
+ }
+
+
+ }
+
+
+
+
+
+
+
+}
+
+#Paths to SDK
+Add-Type -Path "c:\Program Files\Common Files\microsoft shared\Web Server Extensions\15\ISAPI\Microsoft.SharePoint.Client.dll"
+Add-Type -Path "c:\Program Files\Common Files\microsoft shared\Web Server Extensions\15\ISAPI\Microsoft.SharePoint.Client.Runtime.dll"
+
+#Enter the data
+$AdminPassword=Read-Host -Prompt "Enter password" -AsSecureString
+$username="t@testova365.onmicrosoft.com"
+$Url="https://testova365.sharepoint.com/sites/STS"
+$ListTitle="VersionTest"
+
+
+
+Get-sPOFolderFiles -Username $username -Url $Url -password $AdminPassword -ListTitle $ListTitle
\ No newline at end of file
diff --git a/Versioning/Restore previous versions in selected files the entire library/description.md b/Versioning/Restore previous versions in selected files the entire library/description.md
new file mode 100644
index 00000000..b3d3567b
--- /dev/null
+++ b/Versioning/Restore previous versions in selected files the entire library/description.md
@@ -0,0 +1,55 @@
+The script retrieves all files and restores the LAST NOT CURRENT version of the file.
+
+Please test the script in test environment before using it in production.
+
+
+
+The script is a modification of the existing Restore Previous Versions script created to show 2 ways on filtering the file results. The filters are only examples that need to be adjusted to your specific needs.
+
+The first filter uses CamlQuery to retrieve only files coming from a specific folder.
+
+The second filter takes files we have already retrieved and selects only those modified after 12/2/2017.
+
+When dealing with large number of files CamlQuery is the preferred and more efficient way.
+
+
+
+
+
+ The script requires SharePoint Online SDK. Make sure that the paths below point to locations on your computer:
+
+
+
+PowerShell
+#Paths to SDK
+Add-Type -Path "c:\Program Files\Common Files\microsoft shared\Web Server Extensions\15\ISAPI\Microsoft.SharePoint.Client.dll"
+Add-Type -Path "c:\Program Files\Common Files\microsoft shared\Web Server Extensions\15\ISAPI\Microsoft.SharePoint.Client.Runtime.dll"
+
+
+
+
+
+
+
+The script needs to be edited before running. Enter the necessary data:
+
+
+
+```PowerShell
+#Enter the data
+$AdminPassword=Read-Host -Prompt "Enter password" -AsSecureString
+$username="t@testova365.onmicrosoft.com"
+$Url="https://testova365.sharepoint.com/sites/STS"
+$ListTitle="VersionTest"
+```
+The CamlQuery below chooses only files whose ServerRelativeUrl includes a certain path. In this way you can restore versions only from a specific folder.
+PowerShell
+ $spqQuery.ViewXml ="/VersionTest/Folder2/FolderWithinFolder";
+
+ The following lines allow us to narrow the files only to those modified after 12/2/2017.
+PowerShell
+ $date=Get-Date ("2/12/2017")
+
+ if($file.TimeLastModified -gt $date)
+ {
+
diff --git a/Versioning/PS Restore previous versions in the entire library/Restore previous versions.ps1 b/Versioning/Restore previous versions in the entire library/Restore previous versions.ps1
similarity index 83%
rename from Versioning/PS Restore previous versions in the entire library/Restore previous versions.ps1
rename to Versioning/Restore previous versions in the entire library/Restore previous versions.ps1
index dc33fd55..b4efa5b5 100644
--- a/Versioning/PS Restore previous versions in the entire library/Restore previous versions.ps1
+++ b/Versioning/Restore previous versions in the entire library/Restore previous versions.ps1
@@ -2,8 +2,8 @@
{
param (
[Parameter(Mandatory=$true,Position=1)]
- [string]$Username,
- [Parameter(Mandatory=$true,Position=2)]
+ [string]$Username,
+ [Parameter(Mandatory=$true,Position=2)]
[string]$Url,
[Parameter(Mandatory=$true,Position=3)]
$password,
@@ -20,9 +20,9 @@ param (
$ctx.Load($ll)
$ctx.ExecuteQuery()
$spqQuery = New-Object Microsoft.SharePoint.Client.CamlQuery
- $spqQuery.ViewXml ="";
- $itemki=$ll.GetItems($spqQuery)
- $ctx.Load($itemki)
+ $spqQuery.ViewXml ="";
+ $itemki=$ll.GetItems($spqQuery)
+ $ctx.Load($itemki)
$ctx.ExecuteQuery()
foreach($item in $itemki)
@@ -61,13 +61,14 @@ param (
}
if($file.Versions[($file.Versions.Count-1)].IsCurrentVersion)
{
- $vLabel=$file.Versions[($file.Versions.Count-2)].VersionLabel
- Write-Host "Version to be restored: " $vLabel
+ $vLabel=$file.Versions[($file.Versions.Count-2)].VersionLabel
+ Write-Host "Version to be restored: " $vLabel
}
- else{ $vLabel=$file.Versions[($file.Versions.Count-1)].VersionLabel
- Write-Host "Version to be restored: " $vLabel }
- $file.Versions.RestoreByLabel($vLabel)
- $ctx.ExecuteQuery()
+ else{
+ $vLabel=$file.Versions[($file.Versions.Count-1)].VersionLabel
+ Write-Host "Version to be restored: " $vLabel }
+ $file.Versions.RestoreByLabel($vLabel)
+ $ctx.ExecuteQuery()
}
else
diff --git a/Versioning/PS Restore previous versions in the entire library/Restorelast.PNG b/Versioning/Restore previous versions in the entire library/Restorelast.PNG
similarity index 100%
rename from Versioning/PS Restore previous versions in the entire library/Restorelast.PNG
rename to Versioning/Restore previous versions in the entire library/Restorelast.PNG
diff --git a/Versioning/PS Restore previous versions in the entire library/description.md b/Versioning/Restore previous versions in the entire library/description.md
similarity index 100%
rename from Versioning/PS Restore previous versions in the entire library/description.md
rename to Versioning/Restore previous versions in the entire library/description.md
diff --git a/Workflows/Get workflow report for a site collection/workflows in one site coll.ps1 b/Workflows/Get workflow report for a site collection/workflows in one site coll.ps1
index f150886e..3bc49c3d 100644
--- a/Workflows/Get workflow report for a site collection/workflows in one site coll.ps1
+++ b/Workflows/Get workflow report for a site collection/workflows in one site coll.ps1
@@ -5,9 +5,9 @@ param (
[string]$Username,
[Parameter(Mandatory=$true,Position=2)]
$AdminPassword,
- [Parameter(Mandatory=$true,Position=3)]
+ [Parameter(Mandatory=$true,Position=3)]
[string]$Url,
- [Parameter(Mandatory=$true,Position=4)]
+ [Parameter(Mandatory=$true,Position=4)]
[string]$CSVPath
)
@@ -23,12 +23,13 @@ param (
foreach ( $ll in $Lists)
{
- $workflo = $ll.WorkflowAssociations;
- $ctx.Load($workflo);
+ $WorkflowCollection = $ll.WorkflowAssociations;
+ $ctx.Load($WorkflowCollection);
+
try
{
$ctx.ExecuteQuery();
- Write-host $ll.Title $workflo.Count -ForegroundColor Green
+ Write-host $ll.Title $WorkflowCollection.Count -ForegroundColor Green
}
catch [Net.WebException]
@@ -37,15 +38,15 @@ param (
}
- foreach ($workfloek in $workflo)
- {
- $workfloek | Add-Member NoteProperty "SiteUrl"($ctx.Web.Url)
- $workfloek | Add-Member NoteProperty "ListTitle"($ll.Title)
- Write-Output $workfloek
+ foreach ($SingleWorkflow in $WorkflowCollection)
+ {
+ $SingleWorkflow | Add-Member NoteProperty "SiteUrl"($ctx.Web.Url)
+ $SingleWorkflow | Add-Member NoteProperty "ListTitle"($ll.Title)
+ Write-Output $SingleWorkflow
- $workfloek | export-csv -Path $CSVPath -Append
-
- }
+ $SingleWorkflow | export-csv -Path $CSVPath -Append
+
+ }
}
diff --git a/Workflows/Get workflow report for all site collections/description.md b/Workflows/Get workflow report for all site collections/description.md
index e9cf8bc6..fddac1e8 100644
--- a/Workflows/Get workflow report for all site collections/description.md
+++ b/Workflows/Get workflow report for all site collections/description.md
@@ -10,7 +10,7 @@ Before you run the script, open .ps1 file and edit all necessary information:
-PowerShell
+```PowerShell
# Paths to SDK. Please verify location on your computer.
Add-Type -Path "c:\Program Files\Common Files\microsoft shared\Web Server Extensions\15\ISAPI\Microsoft.SharePoint.Client.dll"
Add-Type -Path "c:\Program Files\Common Files\microsoft shared\Web Server Extensions\15\ISAPI\Microsoft.SharePoint.Client.Runtime.dll"
@@ -20,7 +20,7 @@ $Username="user@tenant.onmicrosoft.com"
$AdminPassword=Read-Host -Prompt "Password" -AsSecureString
$AdminUrl="https://tenant-admin.sharepoint.com"
$CSVPath="C:\Users\ivo\Desktop\SomePath.csv"
-
+```
@@ -41,24 +41,16 @@ As the script runs you will see how many workflows each list has:
+
-
-
-
-
-
-
-
-
-
-Sample report
+### Sample report
#TYPE Microsoft.SharePoint.Client.Workflow.WorkflowAssociation
@@ -74,7 +66,7 @@ https://tenant.sharepoint.com/TeamsitewithLists Generic List With GeolocationCol
-Related scripts
+### Related scripts
Get workflow report for one site
diff --git a/Workflows/Get workflow report for one site/description.md b/Workflows/Get workflow report for one site/description.md
index a04f9c7a..6fc8ec37 100644
--- a/Workflows/Get workflow report for one site/description.md
+++ b/Workflows/Get workflow report for one site/description.md
@@ -1,43 +1,39 @@
-rogram Files\Common Files\microsoft shared\Web Server Extensions\15\ISAPI\Microsoft.SharePoint.Client.dll"
-Add-Type -Path "c:\Program Files\Common Files\microsoft shared\Web Server Extensions\15\ISAPI\Microsoft.SharePoint.Client.Runtime.dll"
-
-# Insert the credentials and the name of the site and the path where the report should be saved.
-$Username="2190@tenant.onmicrosoft.com"
-$AdminPassword=Read-Host -Prompt "Password" -AsSecureString
-$Url="https://tenant.sharepoint.com"
-$CSVpath="C:\testpath2.csv"
-
-As the script runs you will see how many workflows each list has:
+Powershell script. Creates a .csv file with a report on all workflows in a site collection.
-
-
-
+Before you run the script, open .ps1 file and edit all necessary information:
+```PowerShell
-
-
-
+# Paths to SDK. Please verify location on your computer.
+Add-Type -Path "c:\Program Files\Common Files\microsoft shared\Web Server Extensions\15\ISAPI\Microsoft.SharePoint.Client.dll"
+Add-Type -Path "c:\Program Files\Common Files\microsoft shared\Web Server Extensions\15\ISAPI\Microsoft.SharePoint.Client.Runtime.dll"
+# Insert the credentials and the name of the site and the path where the report should be saved.
+$Username="2190@tenant.onmicrosoft.com"
+$AdminPassword=Read-Host -Prompt "Password" -AsSecureString
+$Url="https://tenant.sharepoint.com"
+$CSVpath="C:\testpath2.csv"
+```
+As the script runs you will see how many workflows each list has:
+
-
-
-Sample report
+### Sample report
#TYPE Microsoft.SharePoint.Client.Workflow.WorkflowAssociation