I have looked and looked and I can't seen to find a C++ version of GeoIP. I know there is a version of it in C, but I can't seem to get it working with Micosoft Visual Studio 2012 C++
I have tried:
GeoIP is an online database which is updating its data everyday (or monthly!).
Also, You can have a big offline database to map IP-to-Location beside your application (and you need keep it up to date periodically).
GeoIP is not bound to a specific programming language, you can connect to this database using a web-service mechanism. Simply connect to the online service by a TCP/HTTP request and retrieve data.
The HTTP API requires you to pass a set of parameters as an HTTP GET or POST. Results are returned in a simple text format documented below.
We offer several different services, each providing a different amount of information about the IP address.