posts
$envTermGroup = "Document Management Tags" $termSId = "b6ddada5-25b5-xxx-xxxx-b473235d6278" #c65620d8-ee35-4a47-83ed-3da15bf74a0a" #Tags old term set $csvPath = "C:\Users\343614\OneDrive - ssss\Documents\scripts\termsets_import\Import csv - all tags - with synonyms - Delta - test.csv" $logFile = ".\term_synonyms_Log-$(Get-Date -Format "yyyyMMdd-HHmm").csv" function Log-Message { param ( [string]$Message, [string]$Status ) switch ($Status) { "Success" { $color = "Green" } "Info" { $color = "Blue" } "Error" { $color = "Red" } default { $color = "White" } } Write-Host -ForegroundColor $color "$Status => $Message" $logEntry = [PSCustomObject]@{ Timestamp = (Get-Date).
posts
Auto Trimming version - Minor Major # ===== Settings ===== $clientId = "xxxxxxxx" $dateTime = Get-Date -Format "yyyy-MM-dd-HH-mm-ss" $CertPath = Read-Host "Please enter Certificate (.PFX) Path" $CertPassword = Read-Host "Please enter Certificate Password" -AsSecureString $Org = "contoso.onmicrosoft.com" $fileUrl = "https://contoso.sharepoint.com/sites/test/Documents/test_resh_retentionlabel.docx" $invocation = Get-Variable -Name MyInvocation -ValueOnly $directoryPath = Split-Path $invocation.MyCommand.Path function Get-LibraryNameFromFileUrl { param([string]$fileUrl, [string]$siteUrl) # Remove base site URL $relative = $fileUrl.Replace($siteUrl, "") # Trim leading "/" if ($relative.StartsWith("/")) { $relative = $relative.
posts
It seems SharePoint Intelligent Versioning and the 500 Version Limit we may end up with major version of more than 500 as well according to this blog post. Minor versions have been enabled on all SMP libraries and hence minor versions will creep quicker unless users intentionally update to major which does not happen regularly. At the point of initial migration, the retention requirement for the file does not get kicked in probably explaining loss of migrated version if version count is more than 500.