Synch ADA and ADS Schema

From: Vinay Joseph Mathew (vinayjoseph_at_yahoo.com)
Date: 09/28/04


Date: Tue, 28 Sep 2004 16:45:39 -0400

Hi All,

I need an urgent way to synchronize the ADAM schema with the Win2K AD
schema. How do I add attributes like sAMAccountName to ADAM. The code from
W2k is below. The code fails on a lot of places like sAMAccountName,
setpassword etc...

Any help is higly appreciated.

Regards,
Vinay

    Set l_objAdsContainer = GetObject(sAdsPath)
    Set l_user = l_objAdsContainer.Create("user", "cn=" & sAccountID)

    l_user.Put "samAccountName", sAccountID
    l_user.SetInfo

    l_user.Put "DisplayName", sAccountID
    l_user.SetInfo

    l_user.SetPassword "pswd"
    l_user.SetInfo

    l_user.Put "AccountExpires", 0
    l_user.Put "pwdlastset", CLng(-1)
    l_lnewflag = ADS_UF_DONT_EXPIRE_PASSWD
    l_user.Put "userAccountControl", l_lnewflag
    l_user.SetInfo



Relevant Pages

  • Re: ADAM Error: Object Class Violation
    ... it's looks like the definition of a "user" object on your ADAM schema ... does not have one of the attributes that you are trying to load as either ... It's probably sAMAccountName ... > While trying to load the users from .ldf file, ...
    (microsoft.public.windows.server.active_directory)
  • Re: AD-ADAM Sync Error Public Folders
    ... Did you synchronize your AD schema with the ADAM schema? ... when I try to sync AD to ADAM Instance i get ... when trying to sync publicFolders. ...
    (microsoft.public.windows.server.active_directory)
  • Re: ADAM Sync error
    ... on your userProxy that are not standard to the ADAM schema then you will ... need to synchronize your ADAM and AD schema see the notes at the end ... of the following post for help on using ADSchemaAnalyzer to do this: ...
    (microsoft.public.windows.server.active_directory)