Finding the IP Address of my system on asp.net page
I need my system IP address. I've used Request.ServerVariables["remote_addr"] but it is being provided IP address of my network(intranet) not my local system ip.
Actually I've set session state of开发者_JS百科f and want to identify the user request. So i want to fetch the system IP not router/network IP. Please tell me the appropriate solutions.
Request.UserHostAddress. Try this.
try this
how to get ip address of machine in c#
You should be able to use:
Request.ServerVariables["LOCAL_ADDR"]
As seen on: http://msdn.microsoft.com/en-us/library/ms524602(VS.90).aspx
精彩评论