en-US

ExceptIfOneDriveSharedBy

Parameter of AutoSensitivityLabelPolicy

Applies to : Security & Compliance

Description

The ExceptIfOneDriveSharedBy parameter specifies the users to exclude from the policy (the sites of the OneDrive user accounts are included in the policy). You identify the users by UPN ([email protected]).

To use this parameter, one of the following statements must be true:

  • The policy already includes OneDrive sites (in the output of Get-AutoSensitivityLabelPolicy, the OneDriveLocation property value is All, which is the default value).
  • Use -AddOneDriveLocation All in the same command with this parameter.

To enter multiple values, use the following syntax: <value1>,<value2>,...<valueX>. If the values contain spaces or otherwise require quotation marks, use the following syntax: "<value1>","<value2>",..."<valueX>".

You can't use this parameter with the OneDriveSharedBy parameter.

Microsoft Learn documentation

Characteristics

Type
RecipientIdParameter[]
Parameter sets
(All)

Apply

This value type (RecipientIdParameter[]) must be built by hand: see the examples on the policy page and the Microsoft documentation.