title: Reset all Windows 10 user passwords
body: <p>I am deploying Airwatch to my organization. On company-owned laptops, I would like to lock them down if/when the device is ever un-enrolled. There is no built-in method of doing this, so I am looking for a script to do it. My relevant background: I know very little batch, some powershell, a lot of vbscript (for classic ASP). </p>
  
  <p>I would like one or both of the following:</p>
  
  <ul>
  <li>Reset all user passwords on the laptop to something preset</li>
  <li>Create a specific local admin and then disable all other local users</li>
  </ul>
  
  <p>I know I can use "net user" to get a list of users, but I do not know how to use that list to actually disable the users or change their passwords. The batch commands to fit this logic would be ideal:</p>
  
  <pre><code>net user NewAdmin Password /add
  
  net localgroup administrators NewAdmin /add
  
  UserList = net user output
  
  For each UserName in UserList
  
       If UserName &lt;&gt; "NewAdmin" Then
            net user UserName NewPassword
            net user UserName /active:no
       End If
  Next
  </code></pre>