A step by step tutorial teaching you how to create your own chat client and chat server easily in C#, for local networks or the Internet.
A C# tutorial showing you how to make use of WMI to extract information on disk drives, such as model, capacity, sectors and serial number.
This tutorial will teach you how to calculate the shipping cost based on the weight, height, length and depth of the box, the distance and the UPS service type.
Creating a Rich Text Editor using JavaScript is easier to do than you might think, thanks to the support of modern browsers; this tutorial will walk you through it.
Get the IP of a hostGetting the IP address and host name of a host / webhost using System.Net. |
On Tuesday, June 15th 2004 at 11:14 AM By Andrew Pociu (View Profile) ![]() ![]() ![]() ![]() (Rated 4.5 with 11 votes) |
||
The following code asks you for a host and then returns the IP address of that host. The code is self-explanatory thanks to the comments.
Here is an example result:
Also if you want to return the hostname of an IP use Dns.Resolve() instead of Dns.GetHostByName. |
|||
Digg It!
Del.icio.us
Reddit
StumbleIt
Newsvine
Furl
BlinkList
|
|||
|
|||
Current Commentsther reverse can be done very easily too by just exchanging the
Dns.GetHostByName(host);
for
Dns.GetHostByAddress(IP);
this will only work if the dns entry has a reverse lookup though.
i want information about code get ip header in c#
Perfect tutorial!!
Why the application close automatically before I see the result???
Thanks for share this tutorial???
"Why the application close automatically before I see the result???
Thanks for share this tutorial???"
Because it has finished it's job. Add Console.Readline after "try".
Simple but effective!
Why is there a need to get a host's IP? I still don;t get it.
also you can open CMD and write this text :
tracert [your URL]
it is much easyer ;)
Is this guide is safe and secured, this is great if there is no problem on the host system.
on the other hand belong to a category which at best can be called cheap and unworthy. They never give you your desired level of satisfaction. A fake watch is never an exact replacement of a designer or branded watch.
Looks like you don't have permission over the Insert command. Check the user's credentials.and plix help me with the ASP code, for login. i want the registered users to login.When logging in the details should be retrieved from the database.
Thank you for sharing, I will often come to patronize your site
Related Tutorials
Related Source Code
C# Job Search