Skip to content

Set-HideDefaultThemes

SharePoint Online: Sets hide default themes

#Requires -Version 5.1
#Requires -Modules Microsoft.Online.SharePoint.PowerShell

[CmdletBinding()]
Param(
    [Parameter(Mandatory = $true)]
    [bool]$HideDefaultThemes
)

Process {
    try {
        Set-SPOHideDefaultThemes -HideDefaultThemes $HideDefaultThemes -ErrorAction Stop
        [PSCustomObject]@{ Timestamp = Get-Date -Format "yyyy-MM-dd HH:mm:ss"; Status = "Success"; HideDefaultThemes = $HideDefaultThemes.ToString() }
    }
    catch { throw }
}

Set to hide or show default themes

An interactive directory of PowerShell scripts.