User Profile
WJN78
Copper Contributor
Joined 6 years ago
User Widgets
Recent Discussions
Re: Apply sensitivity labels using PowerShell
Jhong3030 Here is an example: # Define the folder path and label IDs $folderPath = "C:\temp\fileswithlabels" $currentLabelId = "<Current_Label_GUID>" # Replace with the GUID of label X $newLabelId = "<New_Label_GUID>" # Replace with the GUID of label Y # Iterate over each file in the folder Get-ChildItem -Path $folderPath -File | ForEach-Object { $file = $_.FullName # Check if the current file has the target label $fileStatus = Get-AIPFileStatus -Path $file if ($fileStatus.LabelId -eq $currentLabelId) { try { # Apply the new label Set-AIPFileLabel -Path $file -LabelId $newLabelId Write-Host "Label changed for file: $file" } catch { Write-Host "Failed to change label for file: $file" } } } Requirement: AIPService Module for Powershell.2.6KViews1like0CommentsRe: Apply sensitivity labels using PowerShell
How would someone using PowerShell change a label on a document? For example, a document was classified as Confidential. A request has come in to have the document reclassified as Internal. Is there a way for the Security Admin to change the classification of the document assuming we do not allow our base to change the classification themselves?41KViews0likes1Comment
Recent Blog Articles
No content to show