New-FimImportChange -Operation 'Replace' -AttributeName "Manager"
Note that you just don't supply the -AttributeValue paramter. However, in my script, I don't want to perform the extra step of checking whether my value is present; so I'd like to do this:
New-FimImportChange -Operation 'Replace' -AttributeName "Manager" -AttributeValue "$newManager"
In order to do that, I had to make a small change to New-FimImportChange in FimPowerShellModule.psm1:
###
### Process the AttributeValue Parameter
###
if (!$AttributeValue)
{
# Allow the caller to pass an empty AttributeValue to unset it, but DO NOT set the AttributeValue on the ImportChange object.
}
elseif ($AttributeValue -is [String])
{
$importChange.AttributeValue = $AttributeValue
}
elseif ($AttributeValue -is [DateTime])