#DEFINE READYSTATE_COMPLETE 4 #DEFINE MAX_TIME 30 local loIE && Internet Explorer object local lcInnerText && Text of the webpage local lcIPAdd && IP Address as a string local lnStartedAt && Seconds when started loading local lnWaiting && Seconds waiting for the document to load local lcRetVal && Return Value loIE = createobject( 'internetexplorer.application' ) lnStarted = SECONDS() loIE.navigate( 'http://www.internet-help.net/cgi-bin/ip-address.pl' ) do while loIE.Readystate <> READYSTATE_COMPLETE or lnWaiting >= MAX_TIME lnWaiting = Seconds() - lnStarted enddo if lnWaiting < MAX_TIME lcInnerText = loIE.Document.Body.InnerText lcIPAdd = allt(substr(lcInnerText , at( ':' , lcInnerText , 2 ) + 1 ) ) lcRetVal = lcIPAdd else lcRetVal = 'Timeout' endif ?lcRetValTIA