Re: Retrieving users email address

Tech-Archive recommends: Repair Windows Errors & Optimize Windows Performance

From: CJM (cjmnews04_at_newsgroups.nospam)
Date: 11/23/04


Date: Tue, 23 Nov 2004 12:39:53 -0000


"Jeff Cochran" <jeff.nospam@zina.com> wrote in message
news:419f294f.1804853622@msnews.microsoft.com...
> On Fri, 19 Nov 2004 16:33:30 -0000, "CJM"
> <cjmnews04@newsgroups.nospam> wrote:
>
>>I'm trying to retrieve the users email address via ADSI in ASP.
>>
>>So far, I have the following code:
>>
>>Set oUser = GetObject("WinNT://domain/" & Request.Form("UID") & ",user")
>>Response.Write oUser.EmailAddress
>>
>>But I get the following message:
>>
>>"The directory property cannot be found in the cache. "
>>
>>Any ideas where I am going wrong?
>
> First guess is you're looking for a directory property that isn't in
> the cache... :)
>
> You're going to need to get specific and tell us versions of OS,
> Active Directory or not, etc. Also, if the email address isn't in
> your directory, you're still not going to get anything.
>
> Jeff

Jeff,

My development server is XPSP2 and we are using Active Directory 2003
(Native mode).

All the email address are populated.

Thanks

Chris



Relevant Pages

  • change password pages
    ... We are having trouble connecting to the Active Directory with these calls ... Active Directory calls from the ASP page? ... The configured identity for the virtual directory in IIS ... ADSI calls, we can get these AD connections to work. ...
    (microsoft.public.inetserver.asp.general)
  • Re: Can I edit AD address information?
    ... I would suggest that you learn the basics of ADSI. ... >> Jeff, ... >> The easiest way would be to use ADModify. ... >> Microsoft Active Directory MVP ...
    (microsoft.public.win2000.active_directory)
  • Re: e-mail address
    ... Using ADSI, connecting to user object and reading email attribute. ... the net on how to use ADSI in ASP. ... Microsoft MVP Windows Server - Active Directory ...
    (microsoft.public.win2000.active_directory)
  • Re: Reformat Server after uninstall active directory?
    ... Jeff, what a vivid figuration! ... >Subject: Re: Reformat Server after uninstall active directory? ...
    (microsoft.public.windows.server.setup)
  • Re: Required attributes for a user account?
    ... creation of the particular object class. ... "Jeff" skrev i meddelandet ... > "Paul Bergson" wrote in message ... >> Bring up the Active Directory Schema via the mmc snap-in, select Classes, ...
    (microsoft.public.windows.server.active_directory)