All but the last two lines of code supplied failed as the asp.net code runs on the server, so gets the server IP & hostname
string getUserHostAddress = HttpContext.Current.Request.UserHostAddress;
string getUserHostName = HttpContext.Current.Request.UserHostName;
Were close, but
HttpContext.Current.Request.UserHostAddress
Referes to the local (ie server machine).
This shoul get what you need:
Request.ServerVariables("REMOTE_ADDR");
Request.ServerVariables("REMOTE_HOST");
But the hostname is largely meaningless across the Internet. This is a useful ref:
http://www.w3schools.com/asp/coll_servervariables.asp[
^]