|
-
Jun 4th, 2006, 11:57 AM
#1
Thread Starter
Hyperactive Member
Winsock_connect() only fires once
Hello,
I have an application, it checks for an internet connection by connecting to a website and then studying the winsock state as it changes. This successfully fires my socket_connect() sub. However, when the socket is then closed, and is used to connect to a different website for a different purpose, the _connect() event doesn't fire. Why?
Can it only fire once or should it fire every time the socket closes and then reconnects using socket.Connect?
Jord
-
Jun 4th, 2006, 01:54 PM
#2
Thread Starter
Hyperactive Member
Re: Winsock_connect() only fires once
I have found the source of the problem, somehow, Winsock must have been corrupted as whenever I try to retrieve a web page using winsock, it returns a load of strange characters, '?''s and spaces.
-
Jun 4th, 2006, 06:01 PM
#3
PowerPoster
Re: Winsock_connect() only fires once
You can connect and reconnect over and over .. do this for each connection
VB Code:
With Form1.Winsock1
.Close
.LocalPort = 0
.Connect RemoteHost, RemotePort
End With
Posting Permissions
- You may not post new threads
- You may not post replies
- You may not post attachments
- You may not edit your posts
-
Forum Rules
|
Click Here to Expand Forum to Full Width
|