Solved

How to modify telephoneNumber AD user property ?

Posted on 2013-01-04
5
1,518 Views
Last Modified: 2013-01-04
Hello,

I am getting the following error once I changed the Telephone number for an AD user.

Type the new TELEPHONE Number:: 3034938004

Are you sure, you want to replace the following Title "303-493-8004" by "3034938004" (Y/N): y
Set-ADUser : A parameter cannot be found that matches parameter name 'telephoneNumber'.
At C:\scripts\AD\test.ps1:136 char:58
+                                 Get-ADUser $AD_User.sAMAccountName  | Set-ADUser -telephoneNumber $Input ...
+                                                                                  ~~~~~~~~~~~~~~~~
    + CategoryInfo          : InvalidArgument: (:) [Set-ADUser], ParameterBindingException
    + FullyQualifiedErrorId : NamedParameterNotFound,Microsoft.ActiveDirectory.Management.Commands.SetADUser

Thanks for your help,
0
Comment
Question by:namerg
  • 3
  • 2
5 Comments
 
LVL 40

Accepted Solution

by:
Subsun earned 500 total points
ID: 38745124
Try with -OfficePhone parameter
Get-ADUser $AD_User.sAMAccountName  | Set-ADUser -OfficePhone $Input
0
 

Author Comment

by:namerg
ID: 38745148
Perfect Subsun.

But, how did you know it was -OfficePhone ?

I go to the ADSI edit and do not see any OfficePhone.

Thanks,
0
 
LVL 40

Expert Comment

by:Subsun
ID: 38745189
I would check with Get-Help or technet reference for parameters.. :-)
0
 
LVL 40

Expert Comment

by:Subsun
ID: 38745311
Here is a good reference for all commands..
http://ss64.com/ps/
0
 

Author Comment

by:namerg
ID: 38745335
Hmm ok. Thanks a million
0

Featured Post

VMware Disaster Recovery and Data Protection

In this expert guide, you’ll learn about the components of a Modern Data Center. You will use cases for the value-added capabilities of Veeam®, including combining backup and replication for VMware disaster recovery and using replication for data center migration.

Question has a verified solution.

If you are experiencing a similar issue, please ask a related question

Set OWA language and time zone in Exchange for individuals, all users or per database.
Disabling the Directory Sync Service Account in Office 365 will stop directory synchronization from working.
This tutorial will walk an individual through the process of transferring the five major, necessary Active Directory Roles, commonly referred to as the FSMO roles from a Windows Server 2008 domain controller to a Windows Server 2012 domain controlle…
This tutorial will walk an individual through the process of configuring their Windows Server 2012 domain controller to synchronize its time with a trusted, external resource. Use Google, Bing, or other preferred search engine to locate trusted NTP …

867 members asked questions and received personalized solutions in the past 7 days.

Join the community of 500,000 technology professionals and ask your questions.

Join & Ask a Question

Need Help in Real-Time?

Connect with top rated Experts

16 Experts available now in Live!

Get 1:1 Help Now