Your question has been submitted and is awaiting moderation.
Does anyone know of a tutorial on this? I have web service working with dnn and I need to change the password. I've found numerous variations for older versions, but I can't find any examples for DNN 7. This is the code I'm trying to use right now.
UserInfo userInfo = UserController.GetUserByName(int.Parse(Properties.Resources.PortalId), un);
MembershipProvider membershipProvider = MembershipProvider.Instance();
if (membershipProvider.PasswordFormat == DotNetNuke.Security.Membership.PasswordFormat.Encrypted)
string oldPassword = UserController.GetPassword(ref userInfo, userInfo.Membership.PasswordAnswer);
string newPassword = UserController.GeneratePassword(membershipProvider.MinPasswordLength);
return(DotNetNuke.Entities.Users.UserController.ChangePassword(userInfo, oldPassword, newPassword)).ToString();