Wrox Programmer Forums
|
ASP.NET 1.1 As of 10/6/2005, this forum is locked as part of the reorganization described here: http://p2p.wrox.com/topic.asp?TOPIC_ID=35394. No posts have been deleted. Open ongoing discussions from the last week have been moved to either ASP.NET 1.0 and 1.1 Beginners http://p2p.wrox.com/asp-net-1-0-1-1-basics-60/ or ASP.NET 1.0 and 1.1 Professional. http://p2p.wrox.com/forum.asp?FORUM_ID=50. See my sticky post inside for more.
Welcome to the p2p.wrox.com Forums.

You are currently viewing the ASP.NET 1.1 section of the Wrox Programmer to Programmer discussions. This is a community of software programmers and website developers including Wrox book authors and readers. New member registration was closed in 2019. New posts were shut off and the site was archived into this static format as of October 1, 2020. If you require technical support for a Wrox book please contact http://hub.wiley.com
 
Old October 13th, 2004, 02:39 AM
Friend of Wrox
 
Join Date: Jun 2004
Posts: 449
Thanks: 0
Thanked 1 Time in 1 Post
Send a message via MSN to r_ganesh76
Default ADSI - Change Password

Hi Experts,

I am using the following code to change the passsword of LDAP users.

DirectoryEntry oUserDE = new DirectoryEntry(Path);
DirectorySearcher oSearch = new DirectorySearcher(oUserDE);
oSearch.Filter = "(userPrincipalName=" + UserID + ")";
SearchResult oResult = oSearch.FindOne();
oUserDE = oResult.GetDirectoryEntry();

oUserDE.Invoke("ChangePassword", new object[]{OldPwd, NewPwd});
oUserDE.CommitChanges();

No error is thrown from these statements. However, the password in not correctly set in the sence, I cannot login using the new password.

Can anyone help me in this matter.

Thanks in Advance

Regards
Ganesh
__________________
Regards
Ganesh
http://ganeshprof.blogspot.com
Find your solution here...





Similar Threads
Thread Thread Starter Forum Replies Last Post
Change AD Password everest C# 2005 2 October 26th, 2007 05:05 PM
Change Password zrtv Pro VB 6 1 September 10th, 2007 07:29 AM
change password code musicdad Classic ASP Databases 1 March 6th, 2005 01:54 AM
change password help budakcomel Classic ASP Databases 0 July 29th, 2003 09:51 PM
How to change the password?? wingtma SQL Server 2000 1 July 8th, 2003 06:27 AM





Powered by vBulletin®
Copyright ©2000 - 2020, Jelsoft Enterprises Ltd.
Copyright (c) 2020 John Wiley & Sons, Inc.