c# - How to grab Client System IP Address? -


I want to capture / track the customer's IP address (machine or user's computer's request). The server is not the machine.

I am working that the customer has inserted the following code to capture / track the IP address of the machine.

  Requests. ServerVariables.Get ("REMOTE_HOST");   

But it is working on the system in which the Internet modem is directly connected to the PC

and I should work on that system in which the Internet modem connect directly Not with PC (connected via router).

You can not get the client's internal address This is what is for that and I know that This is a disappointing answer, but whatever you are asking is not possible in most contexts.

The only exception is, if you control both the client machine and the server For example, in a corporate environment, you can write some tools that will provide that information to the server, of course, random people Asking to go to your website to install your device on your machine is not really a practical choice.

If you provide more detail about your environment and why you want to do this.

Comments

Popular posts from this blog

Verilog Error: output or inout port "Q" must be connected to a structural net expression -

jasper reports - How to center align barcode using jasperreports and barcode4j -

c# - ASP.NET MVC - Attaching an entity of type 'MODELNAME' failed because another entity of the same type already has the same primary key value -