I'm just starting to use winsock and couldn't for the life of me come up with an effective way to detect timeout on connection.
Can anyone help me?
Printable View
I'm just starting to use winsock and couldn't for the life of me come up with an effective way to detect timeout on connection.
Can anyone help me?
you pretty much have to implement one for yourself with an extra timer control,
then somewhere in your code you go into a feedback loop waiting for xxx=true like
VB Code:
'connect and stuff timer1.enabled =true while not downloadcomplete sleep 60 doevents if timer1.enabled = false then msgbox "timed out" end if wend sub timer1_timer() timer1.enabled =false end sub
oops forgot after msgbox exit loop
Thanks for the help. I came up with a similar idea and it works pretty well.