: : Can somebody please tell me how to read the IP number of my computer with vb6 and how to verify if the connection with internet is on?
: : thanks
: :
: Put a WinSock control in your form. Then query its LocalIP proerty. That's you IP address.
:
: If you want to check internet connectivity, just use a web site as a becnhmark. Tell the WinSock control to connect to ... Google, for example, like this:
:
: WinSock1.Connect "www.google.com", 80 'Port 80 is for HTTP
:
:
: If you have the Error event firing, then you most probably don't have internet connection. If, however, the Connect event fires, thn you have successfully connected to the internet. Don't forget to Close the connection to Google, using the Close method of the WinSock.
:
: Hope I helped,
: Nikolay Semov
:
:
Where can I find the winsock control? What's the exact name?
However, many thanks.