title: Get a count of users in a specific OU and its sub OU's
body: <p>I'm looking for a PowerShell script that will get me:  </p>
  
  <ol>
  <li>The name of the <code>OU's</code></li>
  <li>The count of the number of AD users in each <code>OU</code>.</li>
  </ol>
  
  <p>I have found this:</p>
  
  <pre><code>(Get-ADUser -Filter * -SearchBase “ou=Users,ou=A1,dc=contoso,dc=com”).count
  </code></pre>
  
  <p>This does exactly what I want, but I would have to type in each <code>OU</code> name. The problem is that we have 100+ <code>OU's</code>.  The specific <code>OU</code> I'm wanting to run this in is <code>contoso.com\cmsg\users</code>  under the <code>cmsg\users</code> is where the 100+ <code>OU's</code> reside.  </p>