oIP = createobject('MSWinsock.Winsock') lcLocalIP = oIP.LocalIP>I've spent a fair amount (too much) time on this and wanted to share my findings.
>local lcTempFile, loWSH, lcLocalIP >lcTempFile="LocalIP.txt" >if file(lcTempfile) &&erase leftovers from old run > erase (lcTempFile) >endif >loWSH=CreateObject("Wscript.Shell") >loWSH.run("command /c ipconfig > "+lcTempfile,0,1) >if file(lcTempFile) &&read the file and parse it > lcLocalIP=upper(filetostr(lcTempFile)) > lcLocalIP=substr(lcLocalIP, at('IP ADDRESS',lcLocalIP)) > lcLocalIP=substr(lcLocalIP, at(':',lcLocalIP)+2) > lcLocalIP=substr(lcLocalIP, 1, at(chr(13),lcLocalIP)-1) > &&messagebox(lcLocalIP) >endif >>