Update AD user attributes

Hello,

I am trying to use the below command to update the title, department, ipphone, Office, street address, city, state, zip, phone number of user attributes.  

Would someone please check if the parameters are correct?  I am getting error on the IPPhone parameter and also not sure if other parameters are correct.  

Is there a KB that helps me find the name of the correct parameters?  

Thanks.

Set-ADUser -company $user.company -title $user.title -department $user.department -ipPhone $user.ipphone -physicaldeliveryofficename $user.office -streetaddress $user.streetaddress -L $user.city -st $user.state -postalcode $user.postalcode -telephonenumber $user.telephonenumber
}
nav2567Asked:
Who is Participating?

[Product update] Infrastructure Analysis Tool is now available with Business Accounts.Learn More

x
I wear a lot of hats...

"The solutions and answers provided on Experts Exchange have been extremely helpful to me over the last few years. I wear a lot of hats - Developer, Database Administrator, Help Desk, etc., so I know a lot of things but not a lot about one thing. Experts Exchange gives me answers from people who do know a lot about one thing, in a easy to use platform." -Todd S.

Brian BEE Topic Advisor, Independant Technology ProfessionalCommented:
Here is the MS documentation on the command: https://technet.microsoft.com/en-ca/library/ee617215.aspx

I don't think ipphone is a parameter is a valid parameter. What fuctional level are you running at?

I suppose for troubleshooting purpose, just take out that parameter and see if it works.
0
Todd NelsonSystems EngineerCommented:
It doesn't look like the entire script was shared.  Nevertheless, the following are not parameters for Set-ADUser...

  • ipphone
  • st

Instead of "st", use 'state'

Instead of "ipphone", use 'telephoneNumber' 'officephone' 'mobile' 'mobilephone' or 'homephone'.
0
nav2567Author Commented:
I need to update the IpPhone field for the users - please see the attached.  

What should I do?

Thanks.
attr.png
0
Brian BEE Topic Advisor, Independant Technology ProfessionalCommented:
Sorry I totally didn't see this was still unanswered. I don't know if you still need this or not, but Get-ADUser doesn't have an ipPhone property. However you can set it. This would be an example of the code.
Get-ADuser -Identity SomeUser | Set-ADuser -Replace @{ipPhone="1234"}
0

Experts Exchange Solution brought to you by

Your issues matter to us.

Facing a tech roadblock? Get the help and guidance you need from experienced professionals who care. Ask your question anytime, anywhere, with no hassle.

Start your 7-day free trial
Todd NelsonSystems EngineerCommented:
Sufficient information provided for solution.
0
It's more than this solution.Get answers and train to solve all your tech problems - anytime, anywhere.Try it for free Edge Out The Competitionfor your dream job with proven skills and certifications.Get started today Stand Outas the employee with proven skills.Start learning today for free Move Your Career Forwardwith certification training in the latest technologies.Start your trial today
Powershell

From novice to tech pro — start learning today.