Not all keys on keyboard work
Note: This document is for troubleshooting a keyboard with some functioning keys, not keyboards that have no working keys.
Try multiple programs
Make sure the key is not working in more than one application. Some keys such as the function keys F1 through F12 will not work with every program. An easy way to test this is to open notepad or other word processing program and trying the key.
Reboot and try in Safe Mode
If not all keys are working in all programs make sure it's not just a glitch by first rebooting the computer. If this doesn't resolve the issue and you're using Microsoft Windows try the keyboard in Safe Mode.
Clean the keyboard
Remove the key from the keyboard and clean it. In some situations dirt, hair, dust, etc. can obstruct keys causing them not to work.
If all above suggestions have been completed or if you are not running Windows, it is likely that the keyboard or keys are bad and it is recommended that the keyboard be replaced with a new one.