ExcelBanter

ExcelBanter (https://www.excelbanter.com/)
-   Excel Programming (https://www.excelbanter.com/excel-programming/)
-   -   Web Query - Tim Williams xmlhttp Object (https://www.excelbanter.com/excel-programming/414074-web-query-tim-williams-xmlhttp-object.html)

ron

Web Query - Tim Williams xmlhttp Object
 
I have a number of macros that perform various web queries. I
recently came across a post by Tim Williams from 2006 where he uses
the xmlhttp object approach. It seems so elegant, no need to open IE,
no need to wait for IE to load, no screen-scraping - the returned
information is assigned to a variable for further parsing, etc.

So I'm trying to learn a bit more about how to use this approach. The
following url requires two inputs, a method to search by (I typically
use "Street Name") and a street name (let's use "newport").

http://www.bouldercounty.org/assesso...sess_input.asp

I've tried the following bit of code within my sub,

Set my_obj = CreateObject("MSXML2.XMLHTTP")
my_obj.Open "GET", "http://www.bouldercounty.org/assessor/
asrproprecords/assess_input.asp", False, "street_name",
"newport"
my_obj.send
my_var = my_obj.responsetext
Set my_obj = Nothing

but it doesn't bring back the source code from the expected (next)
webpage. I know how to achieve this using the web query / ipf.value
method, but I'd like to figure out how to do it using the xmlhttp
object approach. What is the correct way to provide these inputs
using the xmlhttp object approach? Any help would be much
appreciated...TIA, ron

ron

Web Query - Tim Williams xmlhttp Object
 
Thanks Tim!..ron


All times are GMT +1. The time now is 05:11 PM.

Powered by vBulletin® Copyright ©2000 - 2024, Jelsoft Enterprises Ltd.
ExcelBanter.com