Fix a bug in the FindKey method.

All the last bugs are related with use negative numbers