Hi, i have powershell where i’m getting values from choice field, then i join these vaules from this field with string. I’m doing it because i need copy values from choice to Managed metadada field.
Code:
foreach($varItemLanguage in $varitem.Language){
$varLanguage = "Site Collection - mysitecollection|Language|"+$varItemLanguage;
Write-Host "Item LAnguage:"$varItemLanguage
Write-Host "LAnguage:"$varLanguage
$varLangArray += $varLanguage+" "
write-host "Array: "$varLangArray
}
for first item it works properly and outputs:
Site Collection - mysitecollection|Language|PL Site Collection - mysitecollection|Language|DE and then i put this value to managed metadata column.
For 2nd object it outputs
Site Collection - mysitecollection|Language|PLSite Collection - mysitecollection|Language|DE and then PnP shows warning that term not found.
Please help