🎉 Celebrating 25 Years of GameDev.net! 🎉

Not many can claim 25 years on the Internet! Join us in celebrating this milestone. Learn more about our history, and thank you for being a part of our community!

What function returns the IP address of host machine (locally) with WinSock? <mt>

Started by
0 comments, last by DrJohnB 24 years, 4 months ago
I''m trying to get the internet address of my computer for the current session (changes every time I connect to my ISP I know). I think I have to pass the SOCKADDR_IN structure to a certain function, but I can''t figure out which. I''m looking for either a Win32 or MFC solution. I''m using WinSock, not DirectPlay. I hope you understand my question. Please let me know if I need to make myself clearer. I know there are programs out there that can tell you your computer''s IP address, but I want to write my own so to speak. Thanks for your time.
Advertisement
"Hope that was what you were looking for..."

Boy was it! I was really close, but that worked perfectly. Thank you very much.

Now my chat program is complete!

This topic is closed to new replies.

Advertisement