Thank you very very much for your help! We are trying to retrieve the userdata from a WIN NT server to a UNIX server... So that is the thing!
OK, I will post here the whole script.. hopefully you can help me.. =)
"
cn "{5A5C5A9C-E1BA-42E0-88FE-31EB747A5B54}",name
wscript.echo name
cn "{00003C6E-48FA-4C58-BCDD-AF73D340B464}",name
wscript.echo name
cn "{00004673-535A-448A-A3A2-34C311DD7A44}",name
wscript.echo name
sub cn(guid,name)
' ***************************************************************
' Liefert den Benutzernamen zur GUID / Delivers de username to GUID
' ***************************************************************
adStateOpen=1
' ***************************
' ADO-Instanzierung/ADO instance
' ***************************
set adoConnection=CreateObject("ADODB.Connection")
adoConnection.Provider="ADSDSOObject"
strusername="cn=patonl,cn=users,dc=ldap,dc=derstandard,dc=at"
strpasswort="lnotap"
adoConnection.Open "", strusername,strpasswort
' *****************************************
' Setzen der Verbindung/Opening the connection
' *****************************************
connstr = "<LDAP://ldap.derstandard.at/cn=" & guid & ",ou=webuser,dc=ldap,dc=derstandard,dc=at>;"
connstr = connstr & ";sn,givenname,mail,plainpassword;SubTree"
'connstr = connstr & ";sn,givenname,mail;SubTree"
' ****
' Abfrage
' ****
set adoRecordset=adoConnection.Execute(connstr)
' *********************************************
' Ergebnis wird gesetzt/Result of the query is set
' *********************************************
if not adoRecordset.EOF then
vorname = adoRecordset.Fields.Item("givenName")
nachname = adoRecordset.Fields.Item("sn")
mail = adorecordset.fields.item("mail")
name = vorname & " " & nachname & " " & mail
else
name=""
end if
' *****************************************
' Schließen der Objekte /All objects are closed
' *****************************************
adoConnection.Close
set adoRecordset=nothing
end sub
"
that is it!
Thanks a lot again... I really appreciate it!
Lisandro