SharePoint Online: Disable a Feature for All Sites using PowerShell

Requirement: Disable a feature for all SharePoint Online sites using PowerShell. PowerShell to Deactivate a Site Feature on All Collections in the Tenant We have a requirement to disable the SharePoint Online “Open Documents in Client Applications by Default” feature for all sites in the tenant. Here is the PowerShell to disable…

Read more

SharePoint Online: Bulk Delete Folders from a CSV using PowerShell

Requirement: Bulk Delete Folders in SharePoint Online. How to Bulk Delete Multiple Folders in SharePoint Online? To bulk delete folders with its sub-folders and files, we can use a CSV file with PowerShell script. Here is my CSV file with a list of folder names and the site relative URL of its…

Read more

SharePoint Online: Create Multiple Lists from a CSV File using PowerShell

Requirement: Bulk create lists in SharePoint Online from a CSV File. How to Create Multiple lists from CSV File? We can use the combination of CSV and PowerShell to create multiple lists in bulk in SharePoint Online. Here is my CSV File: You can download this CSV here: PowerShell to Create Multiple…

Read more

SharePoint Online: Bulk Delete Files from a CSV using PowerShell

Requirement: Delete multiple files from SharePoint Online document libraries from a CSV using PowerShell. How to Delete Multiple Files in SharePoint Online Site from a CSV file? We have a CSV file with a list of URLs of various files in multiple document libraries in SharePoint Online. I wanted to bulk delete…

Read more

Fix “Import-Module: The specified module was not loaded because no valid module file was found in any module directory” Error

Problem: When trying to import the PnP PowerShell module, got an error message “Import-Module: The specified module ‘SharePointPnPPowerShellOnline’ was not loaded because no valid module file was found in any module directory” Solution: This is because the PowerShell console or ISE is unable to get the module from given module path’s in…

Read more

How to use an Encrypted Password File in PowerShell Scripts?

Requirement: Use a encrypted password file in PowerShell scripts. How to use an Encrypted Password File to Read/Write Credentials in PowerShell? PowerShell modules like PnP PowerShell offers a mechanism to use Windows credentials store to Save and retrieve user name and password to use it in scripts. However, for other PowerShell modules…

Read more

Getting Started with Home Site in SharePoint Online

What is Home Site in SharePoint Online? Homesite in SharePoint Online is the top landing page for your organization at https://tenant.sharepoint.com/_layouts/15/sharepoint.aspx. The new Set-SPOHomeSite cmdlet sets a modern communication site collection as the SharePoint Online landing page for your organization! So when you click “SharePoint” from the tiles in Office 365 app…

Read more

Create a Communication Site in SharePoint Online using PowerShell

Requirement: Create a communication site in SharePoint Online using PowerShell How to create a Communication Site in SharePoint Online? One of the recent addition to SharePoint Online space is Communication sites! The modern SharePoint Online communication site templates are designed to broadcast information to a broader audience such as to an entire…

Read more

PowerShell to Get All Sites Associated with the Hub Sites in SharePoint Online

Requirement: Get hub site association in SharePoint Online using PowerShell SharePoint Online: Get Hub Sites Association using PowerShell SharePoint Online Hub sites help to organize related sites together into centralized portals based on organizational attributes such as projects, teams, concepts, departments, regions, etc. Hub Sites in SharePoint Online are explained in my…

Read more