You're probably using the older version of Mac OS X, right? You may want to consider upgrading to Leopard at some point... it's quite a bit nicer, and fixes this problem. But anyway, here's what you're going to have to do. Go to the Finder, and into the following folders:
Macintosh HD > Library > Preferences > SystemConfiguration.
Now take the following files, and throw them to the Trash:
com.apple.airport.preferences.plist
com.apple.network.identification.plist
NetworkInterfaces.plist
preferences.plist
You'll probably have to enter your computer password once you put them in the Trash. Now restart your computer, and try going into System Preferences again. It should be solved.