I am using below command to update the hyphen attributes in active directory for 2003 Server Native.
However, I am getting the error while updating the hyphen attribute.
Command :
($ADUserPath = ([adsisearcher]"samaccountname=ABC").FindOne().Path)
($ADuser = [adsi]$ADUserPath)
$ADUser.Put('"cvx-informationSteward"',"ABC")
$ADUser.psbase.CommitChanges()
Error:
Exception calling "CommitChanges" with "0" argument(s): "The specified directory service attribute or value does not
exist.
"
At line:1 char:1
+ $ADUser.psbase.CommitChanges()
+ ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
+ CategoryInfo : NotSpecified: (:) [], MethodInvocationException
+ FullyQualifiedErrorId : DotNetMethodException
Kindly Help