PS C:\Users\songstadw> set-adobject -Identity “526d1e62-f3b7-47ca-ad8d-8061209c0e3b” -replace @{mail=”glenjohn@fabrikam.com”} works. (it is using a well known attribute…
However, both -replace and -add error out when using the custom attribute.
PS C:\Users\songstadw> set-adobject -Identity “526d1e62-f3b7-47ca-ad8d-8061209c0e3b” -replace @{gmailaddress=”glenjohn@fabrikam.com”}
set-adobject : The parameter is incorrect
At line:1 char:1
+ set-adobject -Identity “526d1e62-f3b7-47ca-ad8d-8061209c0e3b” -replace @{gmailad …
+ ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
+ CategoryInfo : InvalidOperation: (526d1e62-f3b7-47ca-ad8d-8061209c0e3b:ADObject) [Set-ADObject], ADInvalidOperationException
+ FullyQualifiedErrorId : The parameter is incorrect,Microsoft.ActiveDirectory.Management.Commands.SetADObject
So I am back to square 0.
Bill