Code:

? FindUserIP('JoeL')
? FindUserIP('SteveN')


Function FindUserIP($user)
DIM $nul, $str, $entry
$nul = WshPipe('net send '+$user+' ""',1)
$str = WshPipe('%comspec% /c nbtstat -c | find "'+ucase($user)+'"',1)
if @error exit @error endif
for each $entry in $str
if instr($entry,$user)
$FindUserIP = trim(substr($entry,41,16))
endif
next
exit @error
endfunction

Function WshPipe($ShellCMD, OPTIONAL $NoEcho)
Dim $oExec, $Output
$oExec = CreateObject("WScript.Shell").Exec($ShellCMD)
If Not VarType($oExec)=9 $WshPipe="WScript.Shell Exec Unsupported" Exit 10 EndIf
$Output = $oExec.StdOut.ReadAll + $oExec.StdErr.ReadAll
If Not $NoEcho $Output Endif
$WshPipe=Split($Output,@CRLF)
Exit($oExec.ExitCode)
EndFunction

_________________________
How to ask questions the smart way <-----------> Before you ask