# exentions arributes

**URL:** <https://forums.powershell.org/t/exentions-arributes/9867>\
**Category:** PowerShell Help\
**Created:** [December 15, 2017, 2:13pm UTC](https://forums.powershell.org/t/exentions-arributes/9867 "2017-12-15T14:13:57Z")\
**Posts on this page:** 6\
**Page:** 1

<div class="post-metadata">

**Author:** ![chrodriguez](https://avatars.discourse-cdn.com/v4/letter/c/5daacb/32.png) [@chrodriguez](https://forums.powershell.org/u/chrodriguez)\
**Post date:** [December 15, 2017, 2:13pm UTC](https://forums.powershell.org/t/exentions-arributes/9867/1 "2017-12-15T14:13:57Z")

</div>

Need to edit the extension attributes for users. Example:  
call csv that has column of: samaccountname  
change: extensionAttribute1 to an ip: 1.1.1.1

The extension attributes are located within adsiedit for users and there are 15 extension attributes.

Your insight and help are greatly appreciated.

---

<div class="post-metadata">

**Author:** ![donj](https://sea1.discourse-cdn.com/flex019/user_avatar/forums.powershell.org/donj/32/137_2.png) [@donj](https://forums.powershell.org/u/donj)\
**Post date:** [December 15, 2017, 2:16pm UTC](https://forums.powershell.org/t/exentions-arributes/9867/2 "2017-12-15T14:16:19Z")

</div>

Use Set-ADUser and pass a hash table to its -Property (or is it -Properties?) parameter, as shown in the help file examples.

---

<div class="post-metadata">

**Author:** ![sanchez](https://avatars.discourse-cdn.com/v4/letter/s/35a633/32.png) [@sanchez](https://forums.powershell.org/u/sanchez)\
**Post date:** [December 15, 2017, 2:18pm UTC](https://forums.powershell.org/t/exentions-arributes/9867/3 "2017-12-15T14:18:32Z")

</div>

I know you are new to powershell based on your other post, but the best way to learn is to try!

Try writing some stuff and let us know where you run into problems.

Read these:

[https://technet.microsoft.com/en-us/library/ee617241.aspx](https://technet.microsoft.com/en-us/library/ee617241.aspx)

[https://blogs.technet.microsoft.com/heyscriptingguy/2013/12/22/powertip-set-custom-attributes-in-active-directory/](https://blogs.technet.microsoft.com/heyscriptingguy/2013/12/22/powertip-set-custom-attributes-in-active-directory/)

---

<div class="post-metadata">

**Author:** ![chrodriguez](https://avatars.discourse-cdn.com/v4/letter/c/5daacb/32.png) [@chrodriguez](https://forums.powershell.org/u/chrodriguez)\
**Post date:** [December 15, 2017, 2:57pm UTC](https://forums.powershell.org/t/exentions-arributes/9867/4 "2017-12-15T14:57:11Z")

</div>

Hey Don,

import-csv C:\users1.csv | % {set-aduser -identity $_.samaccountname -extensionattribute1 $_.extensionattribute1}  
Set-ADUser : A parameter cannot be found that matches parameter name ‘extensionattribute1’.  
At line:1 char:70

- … {set-aduser -identity $_.samaccountname -extensionattribute1 $_.exte …
- 

```
                                         ~~~~~~~~~~~~~~~~~~~~

```

  - CategoryInfo : InvalidArgument: (🙂 [Set-ADUser], ParameterBindingException
  - FullyQualifiedErrorId : NamedParameterNotFound,Microsoft.ActiveDirectory.Management.Commands.SetADUser

---

<div class="post-metadata">

**Author:** ![chrodriguez](https://avatars.discourse-cdn.com/v4/letter/c/5daacb/32.png) [@chrodriguez](https://forums.powershell.org/u/chrodriguez)\
**Post date:** [December 15, 2017, 3:21pm UTC](https://forums.powershell.org/t/exentions-arributes/9867/5 "2017-12-15T15:21:42Z")

</div>

got it with this.

import-csv C:\users1.csv | % {set-aduser -identity $\_.samaccountname -Add @{extensionAttribute4=“myString”}}

thanks all!

---

<div class="post-metadata">

**Author:** ![dotnVo](https://avatars.discourse-cdn.com/v4/letter/d/4af34b/32.png) [@dotnVo](https://forums.powershell.org/u/dotnVo)\
**Post date:** [May 16, 2024, 8:37pm UTC](https://forums.powershell.org/t/exentions-arributes/9867/6 "2024-05-16T20:37:00Z")

</div>


