Tek-Tips is the largest IT community on the Internet today!

Members share and learn making Tek-Tips Forums the best source of peer-reviewed technical information on the Internet!

  • Congratulations Westi on being selected by the Tek-Tips community for having the most helpful posts in the forums last week. Way to Go!

IP Address Conversion

Status
Not open for further replies.

bigozz

Programmer
Apr 12, 2001
39
GB
I have a list of IP addresses which I want to resolve to domain names eg. xxx.xxx.xxx.xxx to
Any ideas on how to do thid with VB?

Thanks
 
Check out MS Knowledgebase article Q160215 HOWTO: Obtain the Host IP Address Using Windows Sockets
 
That works, but it only seems to give me my Host name. My problem is that I have a list of IP address of other peoples machines which I want to resolve to their host name.

Cheers
 

Sure, but the article is just the starting point. It has a link at the bottom to Q154512 SAMPLE: WINSOCK.EXE: Getting HostAddress Using Windows Sockets, which is the generic version.

I guess i should have pointed this out to start with.
 
Use gethostbyaddr function from, wsock32.dll. Look for usage samples in MSDN.

Hope this helps, s-)

Blessed is he who in the name of justice and good will, shepards the week through the valley of darknees...
 
Status
Not open for further replies.

Part and Inventory Search

Sponsor

Back
Top