Jane Lewis's Weblog

Platforms, Active Directory,Administration, Management,Women in Technology, Random Thoughts

Modifying DisplayName Firstname Surname in Active Directory Users and Computers

Modifying DisplayName Firstname Surname in Active Directory Users and Computers

  • Comments 2
  • Likes

Well I was only aware of one particular way to modify the displayname in the Active Directory, and then this only worked for New users.

How to change display names of Active Directory users
http://support.microsoft.com/kb/250455/

Well a colleague of mine pointed me in the direction of some really useful utilities which make this a whole lot easer. Check em out !

Current version of ADModify .NET can be found here:

http://www.codeplex.com/admodify

This task can be also accomplished with other tools like adfind and admod from www.joeware.net. Quick tutorial here:

http://blogs.dirteam.com/blogs/tomek/archive/2006/10/19/ADMod_2C00_-ADFind-_2D00_-user-rename.aspx

This example shows user rename but in the same way (passing results) You can modify displayName.

I thank Tomasz Onyszko  of Microsoft for these great pointers.

Comments
  • Hi Jane,

    I run a little blog on <a href="http://free-activedir-tools.blogspot.com">Free Active Directory Reporting Tools</a> and many of them can actually be used to modify AD data as well.

    If you're ever looking for helpful and FREE AD tools, please feel free to stop by!

    Thanks,

    Marc

  • I am trying to modify details in active directory but only Given name, Display name and surname I am able to change.
    Now I want to change designation and center also but not able to change using the below code. Please help

    PrincipalContext oPrincipalContext = GetPrincipalContext(sDomainName, sServiceUserName, sServicePassword);
    UserPrincipal oUserPrincipal = UserPrincipal.FindByIdentity(oPrincipalContext, sUserName);

    oUserPrincipal.DisplayName = "1";
    oUserPrincipal.GivenName = "2";
    oUserPrincipal.Surname = "3";
    oUserPrincipal.Description = "4";

    oUserPrincipal.Save();
    return oUserPrincipal;

Your comment has been posted.   Close
Thank you, your comment requires moderation so it may take a while to appear.   Close
Leave a Comment