title: asp.net active directory logging in
body: <p>i would like to be able to login on a webpage using a valid active directory username and password.</p>
  
  <p>user name and password are entered in textboxes. if they are correct then i would like to redirect to another page.</p>
  
  <p>how can this be coded.</p>
  
  <p>in a second task</p>
  
  <p>after some code is performed, log in as an administrator using code and unlock the account.</p>
  
  <p>i have heard that this is called impersonation.</p>
  
  <p>how can i perform the above??</p>
  
  <p>i'm using visual web developer 2008 and vb.net</p>
  
  <p>thanks!</p>