Your question does not make any sense, depending on your server the process will differ, and depending on your server application protocol it might not be applicable.
In the case of ASP.net you can access this information via :
Context.Request.ServerVariables ["REMOTE_ADDR"]