Sign in to follow this  
Followers 0
Shifthappens

INetGet Data?

4 posts in this topic

Thanks guys for all the help i've received in my previous posts, but now i'm facing something which seems like jibberish to me. What I think is possible from this is reading a .txt file from a website and if the file says "yes", then the program will work, but if it says "no", then it won't work.

I need to figure out how to check if it says yes or no though.

I want it to read from http://jpres.files.wordpress.com/2007/12/verification.txt

Someone help a noob? :)

Thanks in advance

Share this post


Link to post
Share on other sites



You don't need to use InetGet, but I suppose you could.

I used this code:

#include <IE.au3>
MsgBox(0, "test", Checksite())

Func Checksite()
    $oIE = _IECreate( "http://jpres.files.wordpress.com/2007/12/verification.txt ", 0, 0, 1)
    $tester = _IEBodyReadText( $oIE )
    If $tester = "yes" Then
        Return "yes"
    ElseIf $tester = "no" Then
        Return "no"
    Else
        Return @error
    EndIf
    _IEQuit( $oIE )
EndFunc

Share this post


Link to post
Share on other sites

#3 ·  Posted (edited)

Thanks guys for all the help i've received in my previous posts, but now i'm facing something which seems like jibberish to me. What I think is possible from this is reading a .txt file from a website and if the file says "yes", then the program will work, but if it says "no", then it won't work.

I need to figure out how to check if it says yes or no though.

I want it to read from http://jpres.files.wordpress.com/2007/12/verification.txt

Someone help a noob? :)

Thanks in advance

#include <INet.au3>
If _INetGetSource ( 'http://jpres.files.wordpress.com/2007/12/verification.txt' ) = 'yes' Then
    Msgbox(0,"Program running","The program is now running.")
Endif
Exit

Please read the help file for more information.

- The Kandie Man ;-)

Edited by The Kandie Man

"So man has sown the wind and reaped the world. Perhaps in the next few hours there will no remembrance of the past and no hope for the future that might have been." & _"All the works of man will be consumed in the great fire after which he was created." & _"And if there is a future for man, insensitive as he is, proud and defiant in his pursuit of power, let him resolve to live it lovingly, for he knows well how to do so." & _"Then he may say once more, 'Truly the light is sweet, and what a pleasant thing it is for the eyes to see the sun.'" - The Day the Earth Caught Fire

Share this post


Link to post
Share on other sites

_INetGetSource()

Perfect. A more practical solution than mine. I would use Kandie Man's

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  
Followers 0