how do i set the column name in active directory user search

how do i set the column name in active directory user search with vbscript ?

i created a user named "yehuda testing"

but it looks like that and not showing display name like other userobjects

 search ad
inside it look like this

 properties ad
i used
sAMAccountName,givenName,sn,displayName,userPrincipalName
LVL 14
yehudahaAsked:
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.

TasmantCommented:
ADUC console use ANR (ambiguous name resolution) to display results: http://support.microsoft.com/kb/243299/en-us
When using VBS, you need to specify each attribute you want to return.
If you use recordset, you can write columns like this if you don't know which attribute is in the field.

For i=0 To objRecordSet.Fields.Count-1
	WScript.Echo "Field " & i & ": " & objRecordset.Fields(i).Name
Next

Open in new window

yehudahaAuthor Commented:
i don't think you understood me

i want to know how can i set the name column in the first picture with vbscript, wich attribute ?
TasmantCommented:
as i answered, you cannot really change the "name" column in the MMC itself.
the name column represent any attribute from the ambiguous name resolution, and not one especially.
Has Powershell sent you back into the Stone Age?

If managing Active Directory using Windows Powershell® is making you feel like you stepped back in time, you are not alone.  For nearly 20 years, AD admins around the world have used one tool for day-to-day AD management: Hyena. Discover why.

amnhtechCommented:
You CAN change the name that he is trying to modify, "YehudaT", within the MMC.  I am guessing he wants it to read "yehuda Testing". This can be accomplished by simply right clicking on the name and selecting rename or alternately you can click; pause; click and you will be able to change the name that is displayed.  However, this is not what he wants to do.  He wants to be able to change this using a script cause I am guessing that there are several users who have this problem.  unfortunately I am not sure which user attribute governs that.
yehudahaAuthor Commented:
thanks

Figure It Out

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
yehudahaAuthor Commented:
there is a way you need to modify the "cn" attribute
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
VB Script

From novice to tech pro — start learning today.