in reply to Change AD password

Do you mean a user changing his password?

You might look here as it has good info about AD. Do look at the cookbook reference. It's a good book to have and the author did some Perl for it on his site.