Loading
Scriptbox
 VBScript Links 
 About VBscript 
 JavaScript Links 
 About JavaScript 
 Powershell Links 
 PSCRIPT the Script Launcher 
 PowerShell Shortcut Keys 
 About Powershell 
     VBScript
    JavaScript
    Powershell
Disclaimer
Contact
Latest 10 Scripts
Script search
  :: { Category } :: 0-9ABCDEFGHIJKLMNOPQRSTUVWXYZ
         

Search Options:  Verify  Whether  an  Account  Exists  in  a  Windows  NT  4.0  Domain  

 Content of Verify Whether an Account Exists in a Windows NT 4.0 Domain.vbs
MD5 Hash: E26B1D566FACD77075B4A8D1FA6B4070
' Description: Checks to see if a user account (kenmyer) exists in a Windows NT 4.0 domain named Fabrikam.


strUserName = "kenmyer"
Set objDomain = GetObject("WinNT://fabrikam")
objDomain.Filter = Array("user")
intFound = 0

For Each User In objDomain
If lcase(User.Name) = lcase(strUserName) Then
intFound = 1
End If
Next

If intFound = 1 Then
WScript.Echo "The " & strUserName & " account already exists."
Else
WScript.Echo "The " & strUserName & " account does not exist in the domain."
End If

   © 2008 - 2013 Boris Toll      :: Scripts available: 6.481 ::      :: scriptbox.toll.at ::      :: powered by www.toll.at ::
  Google Entries:n/a
  Yahoo Backlinks:n/a
  Live Backlinks:n/a
  del.icio.us Bookmarks:n/a
  Technorati Links:n/a