hi philip,
Now I am able to get the AD Full name and e-mail address with following code
<%
Dim objSysInfo, objUser
Set objSysInfo =server.CreateObject("ADSystemInfo")
' Currently logged in User
Set objUser = GetObject("LDAP://" & objSysInfo.UserName)
' or specific user:
'Set objUser = GetObject("LDAP://CN=johndoe,OU=Users,DC=ss64,DC=com")
response.Write(objUser.FirstName & " ")
response.Write(objUser.mail)
%>
However this works in my localhost,it is erroring when I try with my IP Address or if I run in any other machine.It gives me the following error.
Error Type:
Microsoft VBScript runtime (0x800A0046)
Permission denied
/CIA_PTT/Preview.asp, line 7
I have even tried with multiple other ways ,all works in localhost(
http://localhost/ADData.asp) but not with my IP ((
http://10.140.28.87/ADData.asp)