Unless it is a high end keyboard, it is not likely that you are going to come out ahead trying to clean it up. I've tried a few back when keyboards were much more expensive than they are now and I still had no real luck. Most of the damage to electronic components occurred at the point when it was wet. The \W is a pretty good indication that something is wacky with the electronics.
However, if you want to try:
1. Unplug the keyboard from the computer (sorry if this sounds insulting, but I'm amazed at how many people don't know there is an electric current in the keyboard).
2. Take off the key caps -- if you don't have the QWERTY keypad memorized, you may want to write it down first. If you are really gutsy, skip this step.
3. Wash as much as you can with warm water. Unfortunately, water is the best solvant for sugar and the worst thing for electronics. Obviously the key caps can be soaked in hot soapy water. If you are really gutsy, soak the keyboard (don't use soap though).
4. Blow dry everything and let stand at least 24 hours. If there is any hint that the keyboard may even be remotely damp, let it dry some more.
At the point that you plug it in to try again, you will find that it miraculously work -- or you made it worse.
My real suggestion is -- go to the store and buy a $16 keyboard.