Make sure you are getting the whole key.
Select the game from your Library, there is a CD-Key link on the right-hand side that will show the serial number.

You can click that and you will see the following window:

Click 'COPY KEY TO CLIPBOARD' and then paste this into the activation dialog:

If your view does not look like that, alternately, you can right click on the game from within your library and choose 'View CD key' or you can hit the option depicted here:
