Thank u for ur quick response.
As i have mentioned before, I need to obtain IP programatically, using any of the API.
Main Topics
Browse All TopicsHi ,
I want the IP of the given URL in windows, basically using Windows API.
Like if given http://www.google.com/ then IP of google.com is 216.239.37.99.
Any help will be rally helpful.
Regards,
Manjesh
This Question has been solved and asker verified All Experts Exchange premium technology solutions are available to subscription members.
Experts Exchange has been collecting answers to technology questions since 1996…3 million and counting! If you have a question, chances are we already have your answer.
If you can't find the exact answer you're looking for, ask our exclusive community of 50,000 experts. You’ll get a personalized answer from a trusted professional.
Thousands of free tech tips, tricks, how-to’s and tutorials are available in our peer reviewed articles section. See for yourself how smart our experts are, no login required.
Access the answers to your technology questions today.
30-day free trial. Register in 60 seconds.
Members of the expert community talk about why the experience at Experts Exchange is different than what you will find anywhere else.

Try it out and discover for yourself.
30-day free trial. Register in 60 seconds.
Join the community of experts here and help other tech pros by answering question in your area of expertise. You can earn FREE access to all Experts Exchange's premium features and resources.
You'll get something like this:
C:\>ping www.google.com
Ping www.google.akadns.net [66.102.11.104] mit 32 Bytes Daten:
Antwort von 66.102.11.104: Bytes=32 Zeit=178ms TTL=240
...
pay attention:
- some websites have more than one IP that are used in a roundtrip
- some IPs are used by more than one webservice, so you can't rely on exchanging the name with the IP (as these websites use the proper name to resolve the service they use at the server with the given IP)
regards Holger
You could use nslookup in a script. From a command line, type "nslookup www.google.com"
I tried nslookup , the result was good. But I dont want to depend on any .exe( like NSLookup, Ping ) . I want to use standard window API ( coz i need to fit in to Window client Application).
So is there any programmtical method of doing this.
Thanks for all ur interest
nslookup msn.com
*** Can't find server name for address 192.168.0.1: Non-existent domain
DNS request timed out.
timeout was 2 seconds.
*** Can't find server name for address 192.168.0.2: Timed out
*** Default servers are not available
Server: UnKnown
Address: 192.168.0.1
Non-authoritative answer:
Name: msn.com
Address: 207.68.172.246
Hi This is a sample code in VBScript
Dim oDNS
' Create object instance
Set oDNS = CreateObject("Emmanuel.Sim
' Declare output variable
Dim found_names
' Set the server address(es)
oDNS.ServerAddresses = "99.99.99.99"
' Set separator for output variable (if multiple results are found)
oDNS.Separator = ", "
' (1) Find IP address of hostname "www.microsoft.com" (Internet class, type A)
On Error Resume Next
oDNS.Resolve "www.microsoft.com", found_names, "C_IN", "T_A"
If Err <> 0 Then
MsgBox Err.Description
Else
' Show resolved names (within dialog box)
MsgBox "Found names:" & vbCrLf & vbCrLf & found_names
End If
' (2) Find Email Servers for domain "microsoft.com"
On Error Resume Next
oDNS.GetEmailServers "microsoft.com", found_names
If Err <> 0 Then
MsgBox Err.Description
Else
' Show resolved names (within dialog box)
MsgBox "Found names:" & vbCrLf & vbCrLf & found_names
End If
Maybe this can help you get the idea.
Madhusudan Banik
Business Accounts
Answer for Membership
by: holger12345Posted on 2005-02-05 at 07:31:35ID: 13233696
Use the command line and "ping www.google.com" ... you get the dns resolved there