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 3e99010a..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,4 +1,4 @@
-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**.
@@ -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/File Management/Readme.md b/File Management/Readme.md
new file mode 100644
index 00000000..9c558e35
--- /dev/null
+++ b/File Management/Readme.md
@@ -0,0 +1 @@
+.
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/Lists and Libraries Management/Column Management/Remove list column/description.md b/Lists and Libraries Management/Column Management/Remove list column/description.md
index a48e14f5..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
@@ -27,9 +27,6 @@ Verify if the SharePoint Online SDK is installed in the same location on your co
-
-
-
### Related scripts
@@ -43,4 +40,4 @@ https://gallery.technet.microsoft.com/scriptcenter/Create-a-new-choice-column-34
-Enjoy and please share feedback!
\ No newline at end of file
+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/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 @@
+