this is a question that can have many answers, first , is there a network interface card in it?, second, is it connected to a ethernet cable, third are the proper drivers installed for the card, fourth can you do an internal loopback? (start,run,type in cmd for win2k and xp, command for win95,98,ME) then type in "ping /127.0.0.1" ,without the quotes and see if it returns a TTL number on four lines, and if it does, you have a connection, the other thing to do is release and renew your adapter
. In the same command box type in "ipconfig /release" then press enter, then type in "ipconfig /renew" , and press enter, then try to get online.if none of this works, the problem is likely with your connection so swap the cable . if all this fails, try to phone your ISP and ask them if you have service hooked up yet!!
there are other factors, if this machine has been running properly previously, it may be a trojan or a browser hihacker, run all your spyware and virus scanners, and use the online scanners also, (Trendmicro housecall, zero spyware, etc.)