=YGoogleMapSearch("11072 Greinerrr Rd., Phila") Procedure YGoogleMapSearch LPARAMETERS lcAddress #DEFINE READYSTATE_COMPLETE 4 clear if not (type("oIE")="O" and not isnull(oIE)) oIE = CreateObject("InternetExplorer.Application") endif oie.visible=.t. lcURL="http://maps.google.com/" oIE.Navigate(lcURL) do while oIE.Readystate <> READYSTATE_COMPLETE wait wind time 1.0 "" enddo oShell = CreateObject("WScript.Shell") lnstart=second() do while not oShell.AppActivate(OIE.DOCUMENT.title) and second()-lnstart <=10 wait wind time 1.0 "Entering ..." ENDDO if oShell.AppActivate(OIE.DOCUMENT.title) oShell.SendKeys(lcAddress+"{ENTER}") WAIT WINDOW TIMEOUT 1.0 "" DO case CASE "Did you mean:" $OIE.DOCUMENT.body.innerText lcresult= SUBSTR(OIE.DOCUMENT.body.innerText, AT("Did you mean:",OIE.DOCUMENT.body.innerText)) ?LEFT(lcresult,AT(CHR(13),lcresult)) ?substr(lcresult,AT(CHR(13),lcresult)+2,AT(CHR(13),lcresult,2) -AT(CHR(13),lcresult)-1) ENDCASE endif RETURN