Developing applications in C# that access resource on the internet is easy. This post shows four useful functions: checking if the PC is connected to a network, domain name to IP address lookup, ping a host and download a file.
Archive for Mono 2.0
A Wrapper Class For hostip.info’s GeoLocation Service
GeoLocation refers to identifying a real-world geographic location of a computer, device or website visitor. There are a many websites that provide this service, some are free and some are not. A populare and free one is hostip.info. It provides country, country code, country flag, city, latitude and longitude of an IP address.
Get a Movie’s Details From IMDb
A while back when I was developing MoviePlay (a movies database) I wanted to allow the user to get the movie’s details from IMDb (The Internet Movie Database) instead of having him/her enter it manually. IMDb does not provide a way for developers to use their data, so I wrote the code below to screen [...]
Reading and Writing Text Files in C#
With all the DBMSs out there, text files are still widely used when developing applications. They are small, fast and do not require any library or application to be installed in the client machine. The System.IO.StreamReader and System.IO.StreamWriter are used to read and write text files to disk.
The following code demonstrates reading a file [...]

