Change User attribute in Active Directory by web (vb.net)

Discussion in 'ASP .Net Security' started by malin@o2.pl, Aug 19, 2005.

  1. Guest

    19 Sie. 09:30 poka¿ opcje
    Grupa dyskusyjna: microsoft.public.adsi.general
    Od: - Znajd¼ wiadomo¶ci tego autora
    Data: 19 Aug 2005 00:30:24 -0700
    Lokalna: Pi±t. 19 Sie. 2005 09:30
    Temat: Change User attribute in Active Directory by web (vb.net)
    Odpowiedz | Odpowiedz autorowi | Przekieruj | Drukuj | Wiadomo¶æ
    prywatna | Poka¿ oryginaln± wiadomo¶æ | Usuñ | Zg³o¶ naruszenie
    prawa lub regulaminu

    Hi

    I have some problem, i modify attributs in .net by web but nothing
    happends, i don;t have any exceptions :(, everything would be okey but
    does'nt :(

    the code :

    dim Entry_ldap As New
    DirectoryEntry("LDAP://hercena11.d450000.wro.mofnet.gov.pl",
    login.text, Password.text)
    Dim lista_atr() As String = {"mail"}
    Dim Filter As String = ("(&(sAMAccountName=" & login.text &
    ")(objectclass=" & "user" & "))")
    Dim my_ldap_user As DirectorySearcher = New
    DirectorySearcher(entry_ldap, Filter, lista_atr)
    my_ldap_user.PropertyNamesOnly = True
    Dim result As SearchResult
    result = my_ldap_user.FindOne()
    result.GetDirectoryEntry.Properties("mail").Value = txt_maillst.Text
    result.GetDirectoryEntry.CommitChanges()

    thanks for all answers
    malin
     
    , Aug 19, 2005
    #1
    1. Advertisements

  2. You multi-posted. Answered in microsoft.public.adsi.general.

    Joe K.

    <> wrote in message
    news:...

    19 Sie. 09:30 poka¿ opcje
    Grupa dyskusyjna: microsoft.public.adsi.general
    Od: - Znajd¼ wiadomo¶ci tego autora
    Data: 19 Aug 2005 00:30:24 -0700
    Lokalna: Pi±t. 19 Sie. 2005 09:30
    Temat: Change User attribute in Active Directory by web (vb.net)
    Odpowiedz | Odpowiedz autorowi | Przekieruj | Drukuj | Wiadomo¶æ
    prywatna | Poka¿ oryginaln± wiadomo¶æ | Usuñ | Zg³o¶ naruszenie
    prawa lub regulaminu

    Hi

    I have some problem, i modify attributs in .net by web but nothing
    happends, i don;t have any exceptions :(, everything would be okey but
    does'nt :(

    the code :

    dim Entry_ldap As New
    DirectoryEntry("LDAP://hercena11.d450000.wro.mofnet.gov.pl",
    login.text, Password.text)
    Dim lista_atr() As String = {"mail"}
    Dim Filter As String = ("(&(sAMAccountName=" & login.text &
    ")(objectclass=" & "user" & "))")
    Dim my_ldap_user As DirectorySearcher = New
    DirectorySearcher(entry_ldap, Filter, lista_atr)
    my_ldap_user.PropertyNamesOnly = True
    Dim result As SearchResult
    result = my_ldap_user.FindOne()
    result.GetDirectoryEntry.Properties("mail").Value = txt_maillst.Text
    result.GetDirectoryEntry.CommitChanges()

    thanks for all answers
    malin
     
    Joe Kaplan \(MVP - ADSI\), Aug 19, 2005
    #2
    1. Advertisements

  3. Pat Guest

    z polski kolega


    <> wrote in message
    news:...

    19 Sie. 09:30 poka¿ opcje
    Grupa dyskusyjna: microsoft.public.adsi.general
    Od: - Znajd¼ wiadomo¶ci tego autora
    Data: 19 Aug 2005 00:30:24 -0700
    Lokalna: Pi±t. 19 Sie. 2005 09:30
    Temat: Change User attribute in Active Directory by web (vb.net)
    Odpowiedz | Odpowiedz autorowi | Przekieruj | Drukuj | Wiadomo¶æ
    prywatna | Poka¿ oryginaln± wiadomo¶æ | Usuñ | Zg³o¶ naruszenie
    prawa lub regulaminu

    Hi

    I have some problem, i modify attributs in .net by web but nothing
    happends, i don;t have any exceptions :(, everything would be okey but
    does'nt :(

    the code :

    dim Entry_ldap As New
    DirectoryEntry("LDAP://hercena11.d450000.wro.mofnet.gov.pl",
    login.text, Password.text)
    Dim lista_atr() As String = {"mail"}
    Dim Filter As String = ("(&(sAMAccountName=" & login.text &
    ")(objectclass=" & "user" & "))")
    Dim my_ldap_user As DirectorySearcher = New
    DirectorySearcher(entry_ldap, Filter, lista_atr)
    my_ldap_user.PropertyNamesOnly = True
    Dim result As SearchResult
    result = my_ldap_user.FindOne()
    result.GetDirectoryEntry.Properties("mail").Value = txt_maillst.Text
    result.GetDirectoryEntry.CommitChanges()

    thanks for all answers
    malin
     
    Pat, Aug 29, 2005
    #3
    1. Advertisements

Want to reply to this thread or ask your own question?

It takes just 2 minutes to sign up (and it's free!). Just click the sign up button to choose a username and then you can ask your own questions on the forum.
Similar Threads
  1. Replies:
    4
    Views:
    7,652
  2. Andy
    Replies:
    3
    Views:
    815
    Charles
    Nov 29, 2005
  3. moi
    Replies:
    1
    Views:
    8,410
  4. Mick Walker

    ASP.NET Adding a User to Active Directory

    Mick Walker, Oct 26, 2007, in forum: ASP .Net
    Replies:
    3
    Views:
    7,990
    Mick Walker
    Oct 26, 2007
  5. Spam Catcher
    Replies:
    4
    Views:
    674
    Willy Denoyette [MVP]
    Apr 21, 2008
  6. Sara
    Replies:
    8
    Views:
    465
    Sara rafiee
    Apr 28, 2004
  7. L Magarian
    Replies:
    3
    Views:
    380
    Joe Kaplan \(MVP - ADSI\)
    Sep 28, 2004
  8. Sergio Lera via .NET 247
    Replies:
    1
    Views:
    393
    Joe Kaplan \(MVP - ADSI\)
    Apr 6, 2005
Loading...