title: query all users in an OU within Active Directory and output usernames to listbox
body: <p>I'm needing to modify a custom attribute we've added to the schema, but on an all user basis. The attribute is an MD5 hash, that I'm already storing as a public variable. I'm trying to get a list of all users within specified OU to be listed within the listbox so that you can select all the users or individual users to have the values applied to.</p>
  
  <p>Here is my current code for Form1.cs</p>
  
  <pre><code>using System;
  using System.Collections.Generic;
  using System.ComponentModel;
  using System.Data;
  using System.Drawing;
  using System.Linq;
  using System.Text;
  using System.Windows.Forms;
  using System.Security.Cryptography;
  using System.DirectoryServices;
  
  
  
  namespace WindowsFormsApplication1
  {
      public partial class Form1 : Form
      {
  
          String Password;
  
          public Form1()
          {
              InitializeComponent();
          }
  
          private void Form1_Load(object sender, EventArgs e)
          {
  
          }
  
          private void textBox1_TextChanged(object sender, EventArgs e)
          {
              Password = textBox1.Text;
          }
  
          private void button1_Click(object sender, EventArgs e)
          {
  
              System.Security.Cryptography.MD5CryptoServiceProvider x = new System.Security.Cryptography.MD5CryptoServiceProvider();
              byte[] bs = System.Text.Encoding.UTF8.GetBytes(Password);
              bs = x.ComputeHash(bs);
              System.Text.StringBuilder s = new System.Text.StringBuilder();
              foreach (byte b in bs)
              {
                  s.Append(b.ToString("x2").ToLower());
              }
              Password = s.ToString();
  
              textBox2.Text = Password;
  
  
          }   
  
          private void button2_Click(object sender, EventArgs e)
          {
  
          }
  
          private void textBox2_TextChanged(object sender, EventArgs e)
          {
  
          }
  
          private void button3_Click(object sender, EventArgs e)
          {
  
          }
  
          private void listBox1_SelectedIndexChanged(object sender, EventArgs e)
          {
  
          }
      }
  }
  </code></pre>