Search Results for

    Show / Hide Table of Contents

    Set-PnPSiteClosure

    SYNOPSIS

    Opens or closes a site which has a site policy applied

    SYNTAX

    Set-PnPSiteClosure -State <ClosureState> [-Connection <PnPConnection>]
     
    

    DESCRIPTION

    Allows to open or close a site which has a site policy applied.

    EXAMPLES

    EXAMPLE 1

    Set-PnPSiteClosure -State Open
    

    This opens a site which has been closed and has a site policy applied.

    EXAMPLE 2

    Set-PnPSiteClosure -State Closed
    

    This closes a site which is open and has a site policy applied.

    PARAMETERS

    -Connection

    Optional connection to be used by the cmdlet. Retrieve the value for this parameter by either specifying -ReturnConnection on Connect-PnPOnline or by executing Get-PnPConnection.

    Type: PnPConnection
    Parameter Sets: (All)
    
    Required: False
    Position: Named
    Default value: None
    Accept pipeline input: False
    Accept wildcard characters: False
    

    -State

    The state of the site

    Type: ClosureState
    Parameter Sets: (All)
    Accepted values: Open, Closed
    
    Required: True
    Position: Named
    Default value: None
    Accept pipeline input: False
    Accept wildcard characters: False
    

    RELATED LINKS

    Microsoft 365 Patterns and Practices

    Back to top Generated by DocFX spacer