To get MAC from IP, you can use IP Helper API.
http://msdn.microsoft.com/
Main Topics
Browse All TopicsI'm trying to programatically get the information which is returned by running the call nbtstat. Basically, I want to get a look at a computers Netbios Name Table. Unfortunately, all I have is the computers IP address.
From what I can tell, you can use the NetBios() call to get the Name table of a computer, but you need to have the computer's MAC address to make the NetBios() call. ( Actually, I'm not even sure that would work come to think of it. I'm on a different physical network than the computer I'm querying.) At any rate, I can't find a way to translate between IP and MAC. Win2k has SendArp() but I need something for general Win32. And writing my own arp driver appears to require raw socket access which has the same problem.
Can anyone tell me how to get the name table nbtstat will display to you. Am I on the right track? If so, how can I get the right MAC Address? Any tips appreciated.
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.
To get MAC from IP, you can use IP Helper API.
http://msdn.microsoft.com/
Business Accounts
Answer for Membership
by: nothingmanPosted on 2001-08-29 at 22:59:56ID: 6439365
Slight clarification. nbtstat is not a call. It's a program that ships with Windows. You give it an IP and it gives you the Name table.