Where is the description field?

  • Thread starter Thread starter Jon Paskett
  • Start date Start date
J

Jon Paskett

I am looking for the Description Field displayed in Active Directory Users
and Computers. I can right click and add them thru the snap-in but I want to
do it at the PC.

I'm not looking for the srvcomment located at
HKEY_LOCAL_MACHINE\SYSTEM\CurrentControlSet\Services\lanmanserver\parameters

TIA <JP>
 
Jon said:
I am looking for the Description Field displayed in Active Directory Users
and Computers. I can right click and add them thru the snap-in but I want to
do it at the PC.

I'm not looking for the srvcomment located at
HKEY_LOCAL_MACHINE\SYSTEM\CurrentControlSet\Services\lanmanserver\parameters

Hi

AD properties is e.g. documented in MSDN:

Platform SDK: Directory Services, IADsUser
http://msdn.microsoft.com/library/en-us/netdir/adsi/iadsuser.asp

IADsUser Property Methods
http://msdn.microsoft.com/library/en-us/netdir/adsi/iadsuser_property_methods.asp

Class Details: User
http://msdn.microsoft.com/library/en-us/adschema/ad/win2k_c_user.asp

Also, check out ADSI Edit to look up property names.
ADSI Edit is part of the "Windows 2000 Support Tools" on
any W2k server CD. It can be installed on any w2k or xp client by running
Setup.exe in the \Support\Tools folder on the CD. With ADSI Edit, you can browse

(and edit) all objects in AD and view all their properties (and the values).


You can enumerate all properties of any AD object, whether assigned a value or
not, as follows (a Richard Mueller script):

Option Explicit
Dim oObject, sProp, oClass, sAdsPath

sAdsPath = "LDAP://cn=TestUsr,ou=Sales,dc=MyDomain,dc=com"

' Bind to Active Directory object.
Set oObject = GetObject(sAdsPath)

Set oClass = GetObject(oObject.Schema)

' Enumerate mandatory properties of the object.
For Each sProp In oClass.MandatoryProperties
Wscript.Echo "(M) " & sProp
Next

' Enumerate optional properties of the object.
For Each sProp In oClass.OptionalProperties
Wscript.Echo "(O) " & sProp
Next

You can run this at a command prompt with the cscript host
and redirect the output to a text file. If the VBScript is
called Property.vbs:

cscript //nologo Property.vbs > property.txt
 
Jon said:
I am looking for the Description Field displayed in Active Directory Users
and Computers. I can right click and add them thru the snap-in but I want to
do it at the PC.

I'm not looking for the srvcomment located at
HKEY_LOCAL_MACHINE\SYSTEM\CurrentControlSet\Services\lanmanserver\parameters

Hi

AD properties is e.g. documented in MSDN:

Platform SDK: Directory Services, IADsUser
http://msdn.microsoft.com/library/en-us/netdir/adsi/iadsuser.asp

IADsUser Property Methods
http://msdn.microsoft.com/library/en-us/netdir/adsi/iadsuser_property_methods.asp

Class Details: User
http://msdn.microsoft.com/library/en-us/adschema/ad/win2k_c_user.asp

Also, check out ADSI Edit to look up property names.
ADSI Edit is part of the "Windows 2000 Support Tools" on
any W2k server CD. It can be installed on any w2k or xp client by running
Setup.exe in the \Support\Tools folder on the CD. With ADSI Edit, you can browse

(and edit) all objects in AD and view all their properties (and the values).


You can enumerate all properties of any AD object, whether assigned a value or
not, as follows (a Richard Mueller script):

Option Explicit
Dim oObject, sProp, oClass, sAdsPath

sAdsPath = "LDAP://cn=TestUsr,ou=Sales,dc=MyDomain,dc=com"

' Bind to Active Directory object.
Set oObject = GetObject(sAdsPath)

Set oClass = GetObject(oObject.Schema)

' Enumerate mandatory properties of the object.
For Each sProp In oClass.MandatoryProperties
Wscript.Echo "(M) " & sProp
Next

' Enumerate optional properties of the object.
For Each sProp In oClass.OptionalProperties
Wscript.Echo "(O) " & sProp
Next

You can run this at a command prompt with the cscript host
and redirect the output to a text file. If the VBScript is
called Property.vbs:

cscript //nologo Property.vbs > property.txt
 
Back
Top