If the wireless network you're trying to connect to is secured (encrypted with WEP, WPA, or WPA2), you'll be prompted to enter the network password (sometimes twice). Once you enter the key, it'll be saved for you for next time.
Newer operating systems will notify you if you enter the wrong password, but some XP versions didn't--meaning that you would enter the incorrect password and it would look like you connected to the network, but you didn't really and couldn't access the resources. So be careful when entering the network key.
Also, if this is your home network and you've forgotten your wireless security passphrase or key, you may be able to find it on the bottom of your router if you didn't change the defaults when setting up your network. Another alternative, on Windows, is to use the "Show characters" box to reveal the Wi-Fi network password. In short, click on the wireless icon in your taskbar, then right-click on the network to "view connection properties." Once there, you'll see a checkbox to "Show characters." On a Mac, you can view the wireless network password in the Keychain Access app (under the Applications > Utilities folder).