Home | Contact Us | FAQ | Search & Site Map | Link to Us
Sign In | Join | Other 45 Sites in Network
HomeAnnouncementsFree MagazinesWhite PapersSubmit Content
Discussion GroupsASP.NETWindows FormsLanguages.NET FrameworkVisual Studio.NET
Articles.NET FrameworkASP.NETToolsWindows Forms
.NET DirectoryOpen Source ProjectsUser GroupsWeb Resources
Related Topics
Visual Basic 6SQL ServerMS AccessOther DB ProductsMS Server ProductsMore Topics ...

.NET Forum / ASP.NET / General / March 2008

Tip: Looking for answers? Try searching our database.

Vista - IP Address

Thread view: 
Enable EMail Alerts  Start New Thread
Thread rating: 
Santel - 07 Mar 2008 06:36 GMT
Hi,

Anyone please suggest me to retrieve the Vista machine's IP Address
from asp.net. I tried Request.ServerVariables["REMOTE_ADDR"], but no
success.
Mufaka - 07 Mar 2008 06:47 GMT
> Hi,
>
> Anyone please suggest me to retrieve the Vista machine's IP Address
> from asp.net. I tried Request.ServerVariables["REMOTE_ADDR"], but no
> success.

Try Request.UserHostAddress.
Santel - 07 Mar 2008 07:42 GMT
Thanks for the update. But this also returns the same value "::1"
Rick Strahl - 12 Mar 2008 06:21 GMT
That's correct actually. ::1 is the IP V6  localhost IP address (ie.
equivalent to 127.0.0.1).

If you need IP V4 regular IP addresses you can turn off IP V6 on your net
connection.Or probably better convert an IP 6 Address using the Dns class.

This article should help:
http://aspnet.4guysfromrolla.com/articles/071807-1.aspx

Not sure though what the perf implications are of doing this.

+++ Rick ---

---
Rick Strahl
West Wind Technologies
www.west-wind.com/weblog

> Thanks for the update. But this also returns the same value "::1"
Mark Rae [MVP] - 12 Mar 2008 11:39 GMT
> This article should help:
> http://aspnet.4guysfromrolla.com/articles/071807-1.aspx

Indeed... :-)

> Not sure though what the perf implications are of doing this.

I haven't noticed any so far...

Signature

Mark Rae
ASP.NET MVP
http://www.markrae.net


Rate this thread:







Free Magazines

Get these publications absolutely FREE for up to 12 months. There are no hidden fees and no obligation. Simply choose a title, complete the application form and submit it. Read more ...

Oracle MagazineNetwork ComputingComputer WorldBio-IT WorldeWeekInformation WeekInfosecurity
 
Sign In
Join
My Latest Posts
My Monitored Threads
My Blog
My Photo Gallery
My Profile
My Homepage

Start New Thread
Enable EMail Alerts
Rate this Thread



©2008 Advenet LLC   Privacy Policy - Terms of Use
This website includes both content owned or controlled by Advenet as well as content owned or controlled by third parties.