Solved

LDAP for VB

Posted on 2001-07-25
7
538 Views
Last Modified: 2010-05-18
I want to connect and authenticate user to an LDAP server using VB. I also want to change my password on the LDAP server using VB. Are there any available OCX (free) that can be used? Any sample

Thanks
0
Comment
Question by:puruknoy
  • 4
  • 2
7 Comments
 
LVL 8

Expert Comment

by:Dave_Greene
ID: 6316914
Go here and search the page for LDAP.. they have code samples

http://developer.novell.com/support/sample/areas/vbs.htm
0
 

Accepted Solution

by:
jackyx earned 200 total points
ID: 6316942
You must install the ADSI runtime (ADS.EXE) available from www.microsoft.com/ntserver/info/adsi.htm, and then add a reference to Active DS Type Library.

Note: Windows 2000 includes the ADSI 2.5 runtime. Installation of the above runtime is not required.

Here is some code snippet (not completed) but it will help you get going.  Once you referenced ADSI 2.5 you will find all objects in the object explorer (F2 key).

You will find all the needed info in the net or look at the ADSI samples in VB from Microsoft website.

...
'Declaration here
Dim machinename As IADs...
Dim username As IADS...
...
'Make the ADSI call for password change
Set oUser = GetObject("WinNT://machinename/username")
oUser.ChangePassword "oldpassword", "newpassword"
oUser.SetInfo
Set oUser = Nothing
...

Well i hope this was what you needed.

Regards

jackyx
0
 
LVL 8

Expert Comment

by:Dave_Greene
ID: 6316963
jackyx.

Please the the section "Tips on Comments and Answers" at the bottom of this page.

Hint:  if you have to put something like ("Well i hope this was what you needed.") in your post, it should probably be a comment.

Thanks

Dave
0
Free Tool: Path Explorer

An intuitive utility to help find the CSS path to UI elements on a webpage. These paths are used frequently in a variety of front-end development and QA automation tasks.

One of a set of tools we're offering as a way of saying thank you for being a part of the community.

 

Author Comment

by:puruknoy
ID: 6320347
I still have to try that solution, Dave green was right but anyway thanks for the tip and effort.
0
 

Author Comment

by:puruknoy
ID: 6320403
Dave_Green, where can i find the LDAPSDK Library to be used in the VB sample program?

http://developer.novell.com/support/sample/areas/vbs.htm 

Thanks
0
 

Author Comment

by:puruknoy
ID: 6320522
Dave_Green, where can i find the LDAPSDK Library to be used in the VB sample program?

http://developer.novell.com/support/sample/areas/vbs.htm 

Thanks
0
 

Author Comment

by:puruknoy
ID: 6320587
Dave_Green, where can i find the LDAPSDK Library to be used in the VB sample program?

http://developer.novell.com/support/sample/areas/vbs.htm 

Thanks
0

Featured Post

Free Tool: Path Explorer

An intuitive utility to help find the CSS path to UI elements on a webpage. These paths are used frequently in a variety of front-end development and QA automation tasks.

One of a set of tools we're offering as a way of saying thank you for being a part of the community.

Question has a verified solution.

If you are experiencing a similar issue, please ask a related question

Suggested Solutions

Introduction In a recent article (http://www.experts-exchange.com/A_7811-A-Better-Concatenate-Function.html) for the Excel community, I showed an improved version of the Excel Concatenate() function.  While writing that article I realized that no o…
Most everyone who has done any programming in VB6 knows that you can do something in code like Debug.Print MyVar and that when the program runs from the IDE, the value of MyVar will be displayed in the Immediate Window. Less well known is Debug.Asse…
Get people started with the utilization of class modules. Class modules can be a powerful tool in Microsoft Access. They allow you to create self-contained objects that encapsulate functionality. They can easily hide the complexity of a process from…
This lesson covers basic error handling code in Microsoft Excel using VBA. This is the first lesson in a 3-part series that uses code to loop through an Excel spreadsheet in VBA and then fix errors, taking advantage of error handling code. This l…

856 members asked questions and received personalized solutions in the past 7 days.

Join the community of 500,000 technology professionals and ask your questions.

Join & Ask a Question