Jump to content
Sign in to follow this  
megahyperion

winhttp com example in help file

Recommended Posts

In the example

$oHTTP = ObjCreate("winhttp.winhttprequest.5")

$oHTTP.Open("GET","http://www.AutoItScript.com")

$oHTTP.Send()

$HTMLSource = $oHTTP.Responsetext

What does the .5 mean after the winhttprequest ?

Share this post


Link to post
Share on other sites

I believe it is the version of winhttp on your system, as Sven has posted similar code before? Though some may need to use version 5.1.

Edited by MHz

Share this post


Link to post
Share on other sites

OK one more on this subject

Why would something like this

$oHTTP = ObjCreate("winhttp.winhttprequest.5")

$oHTTP.Open

Do something differently then this

$oHTTP = ObjCreate("winhttp.winhttprequest")

$oHTTP.5.Open

or this

$oHTTP = ObjCreate("winhttp.winhttprequest.5.Open")

To me it all looks like it should do the same thing, after a ton of reading the only thing I can think of for the . is that its like a / in a directory name.

Maybe I have the whole concept wrong.

Share this post


Link to post
Share on other sites

becuze you need more then only the open() command

$httpObj = ObjCreate("winhttp.winhttprequest.5.1")
$httpObj.open("GET",$URL)
$httpObj.send()

$HTMLSource = $httpObj.Responsetext

so this would be the smallest i think


My UDF's:;mem stuff_Mem;ftp stuff_FTP ( OLD );inet stuff_INetGetSource ( OLD )_INetGetImage _INetBrowse ( Collection )_EncodeUrl_NetStat_Google;random stuff_iPixelSearch_DiceRoll

Share this post


Link to post
Share on other sites

Create an account or sign in to comment

You need to be a member in order to leave a comment

Create an account

Sign up for a new account in our community. It's easy!

Register a new account

Sign in

Already have an account? Sign in here.

Sign In Now
Sign in to follow this  

  • Recently Browsing   0 members

    No registered users viewing this page.

×
×
  • Create New...