Check your game's version number.
The codes floating around target version 1.60. If your cartridge is an earlier revision, the cheats won't take — you'll need to update to match before anything works.
It's a common frustration, and the version mismatch is nearly always the reason.