Display should be First name + Last name

Welcome Forums General PowerShell Q&A Display should be First name + Last name

Viewing 1 reply thread
  • Author
    Posts
    • #197858
      Participant
      Topics: 4
      Replies: 2
      Points: 29
      Rank: Member

      Hi Guys,

      I have changed my last names to capitals and its not effecting in display name

      I run the below script made the changes in AD lastnames

      $targetUsers = Get-ADuser -SearchBase “OU=India,DC=study,DC=com” -Filter {Surname -Like “*”} | Select DistinguishedName, Surname
      $targetUsers | foreach-object {

      set-aduser $_ -Surname $_.surname.toupper()
      }

      now i want to change Display name as first + Last name.

      Present Display Name is : kiran manne

      So My Display name should be like = kiran MANNE

    • #197897
      Participant
      Topics: 13
      Replies: 1691
      Points: 2,882
      Helping Hand
      Rank: Community Hero

      There is a DisplayName attribute, which you set with Set-ADUser. The actual object name can be updated with Rename-ADObject.

Viewing 1 reply thread
  • The topic ‘Display should be First name + Last name’ is closed to new replies.