>*- Google maps address verification >=YGoogleMapSearch("11 Chestnut Ridge, Tannersville PA") >RETURN > >* >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?q=" + lcAddress > >oIE.NAVIGATE(lcURL) > >DO WHILE oIE.Readystate <> READYSTATE_COMPLETE > WAIT WIND TIME 1.0 "" >ENDDO > >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) > >CASE "Address:"+CHR(13) $oIE.DOCUMENT.body.innerText > > lcresult= SUBSTR(oIE.DOCUMENT.body.innerText, AT("Address:"+CHR(13),oIE.DOCUMENT.body.innerText)) > lcout=lcresult > ilines=1 > > DO WHILE lcout <> "A." AND ilines<5 > ?LEFT(lcout,AT(CHR(13),lcout)-1) > lcout=SUBSTR(lcout,AT(CHR(13),lcout)+2) > ilines=ilines+1 > ENDDO > >OTHERWISE > lcresult = oIE.DOCUMENT.body.innerText > STRTOFILE(lcresult,'temp.txt') > >ENDCASE > > >RETURN >>>Here's the entire code. I added your CASE, but I still get the same result in the TEMP.TXT file. The code is in a file TEMP.PRG and I just enter DO TEMP from the command window.