Thread: How to Check internet Connection ???

  1. #1
    Registered User
    Join Date
    Dec 2010
    Location
    Lucknow, India
    Posts
    72

    Smile How to Check internet Connection ???

    Hi. Im working on a Program in C.. in the middle of Which I need to Check whether the Internet is Connected to the PC or NOT... and Further operations are based on the Result.. But I dont know how to do it.. I also tried to Find the IP address.. But not able to do so too..
    I used some of the Windows Library Functions but my Compiler gives the Error..
    Someone Please Suggest a Better Function or a Better way to get out of it..!!! :-)

    OS: Windows Xp
    Compiler: BC++ 5.5
    There is a Real magic in enthusiasm, It spells the difference between mediocrity and accomplishments.

  2. #2
    Registered User
    Join Date
    May 2011
    Location
    Around 8.3 light-minutes from the Sun
    Posts
    1,949
    May I suggest some things:

    1. Look at this.
    2. Then you could look here
    3. Get a new compiler.
    4. Then you might be able to Ask a smart question
    Quote Originally Posted by anduril462 View Post
    Now, please, for the love of all things good and holy, think about what you're doing! Don't just run around willy-nilly, coding like a drunk two-year-old....
    Quote Originally Posted by quzah View Post
    ..... Just don't be surprised when I say you aren't using standard C anymore, and as such,are off in your own little universe that I will completely disregard.
    Warning: Some or all of my posted code may be non-standard and as such should not be used and in no case looked at.

  3. #3
    ATH0 quzah's Avatar
    Join Date
    Oct 2001
    Posts
    14,826
    5. Read Beej's guide to socket programming.


    Quzah.
    Hope is the first step on the road to disappointment.

  4. #4
    Banned
    Join Date
    Aug 2010
    Location
    Ontario Canada
    Posts
    9,547
    Quote Originally Posted by Gaurav Singh View Post
    Hi. Im working on a Program in C.. in the middle of Which I need to Check whether the Internet is Connected to the PC or NOT... and Further operations are based on the Result.. But I dont know how to do it.. I also tried to Find the IP address.. But not able to do so too..
    I used some of the Windows Library Functions but my Compiler gives the Error..
    Someone Please Suggest a Better Function or a Better way to get out of it..!!! :-)

    OS: Windows Xp
    Compiler: BC++ 5.5
    IsNetworkAlive Function (Windows)

Popular pages Recent additions subscribe to a feed

Similar Threads

  1. Internet Connection
    By earth_angel in forum C++ Programming
    Replies: 1
    Last Post: 08-16-2005, 07:43 AM
  2. Speed up any Internet Connection!
    By Stan100 in forum Tech Board
    Replies: 5
    Last Post: 07-13-2004, 10:30 AM
  3. Internet Connection
    By Stan100 in forum Windows Programming
    Replies: 2
    Last Post: 04-28-2004, 09:49 AM
  4. internet connection autostart
    By beely in forum Tech Board
    Replies: 9
    Last Post: 06-24-2003, 07:08 AM
  5. internet connection
    By onurak in forum Linux Programming
    Replies: 3
    Last Post: 10-02-2002, 08:48 AM