-
In my Winsock dataarival i have something like this:
Code:
dim yaya as string
winsock1.getdata yaya
If InStr(1, yaya, "User Registration Confirmation") <> Then
msgbox "Confirmation OK"
Winsock1.Close
end if
winsock1.connect server, 80
Now, on some slow servers, the donwloaded data does get to finish so it cant find the "user registration" string that is at the bottom of the page. What can I put in data arival that will make sure the whole Document is finished before going on and connecting again with the winsock1.connect.
Any help is appreciated.
-
Hiya lol
ok I assume you are downloading this data from a webpage, in which case after the webpage has finished sending the data to your app it closes the connection.
so in your general declarations put something like:
Dim WebpageSource as string
then in your winsock data arrival,
dim yaya as string
winsock1.getdata yaya
webpagesource = webpagesource & yaya
then in your winsock close sub put:
If InStr(1, webpagesource, "User Registration Confirmation") <> Then
msgbox "Confirmation OK"
Winsock1.Close
end if
winsock1.connect server, 80
hope that helps.
-
Thanks, it worked. My prog is running smooth!
Thanks for helping again. This is the second time :)