Internet, Returning Host name from WinShock

‘Description: Asynchronous routine which returns the true host name given
‘             an IP address, or Web address.

‘Handle = WSAAsyncGetHostByNameAlias(Text1.hWnd, &H202, “”)

‘Public Function WSAAsyncGetHostByNameAlias(hWnd As Integer, wMsg As Integer, Host As String) As Long
Dim retIP As Long
retIP = inet_addr(Host)
retIP = WSAAsyncGetHostByName(hWnd, wMsg, Host, hostentbuffer, hostentasync_size)
retIP = WSAAsyncGetHostByAddr(hWnd, wMsg, retIP, 4, AF_INET, hostentbuffer, hostentasync_size)
End If
WSAAsyncGetHostByNameAlias = retIP
‘End Function


One response to “Internet, Returning Host name from WinShock

Leave a Reply

Fill in your details below or click an icon to log in: Logo

You are commenting using your account. Log Out / Change )

Twitter picture

You are commenting using your Twitter account. Log Out / Change )

Facebook photo

You are commenting using your Facebook account. Log Out / Change )

Google+ photo

You are commenting using your Google+ account. Log Out / Change )

Connecting to %s