The article describes the process of changing the passwords for all the users at once or batches of users in your Active Directory. You can:

Setting unique password for the users

  1. Create a .CSV file containing usernames:
    1. Start > Run > type cmd
    2. In Command Prompt type csvde -m -f MyUsers.csv -r "(&(objectClass=user)(mail=*))" -l sAMAccountName cmd
  2. Open the CSV file in Excel, delete the first column (DN) and type user passwords into a second column. Save the file.
  3. In Command Prompt type

    for /F "tokens=1,2 delims= " %i in (MyUsers.csv) do net user %i %j /domain

    Important: parenthesis in the above command are required.

Setting the same password for the users

This might be needed when you need to change all the passwords urgently and would like the users to change the passwords by themselves later.

  1. Start > Run > type cmd
  2. In Command Prompt type csvde -m -f MyUsers.csv -r "(&(objectClass=user)(mail=*))" -l sAMAccountName
  3. Open the CSV file in Excel, delete the first column (DN) and type user passwords into a second column. Save the file.
  4. In Command Prompt type

    for /F "tokens=1,2 delims= " %i in (MyUsers.csv) do net user %i %j /domain


    Important:
    parenthesis in the above command are required.