gilda1975 Have you tried redeeming the code in the EA App? If you open your game library, you'll see a button to add a game/code, and as long as you haven't already registered the game, you should be able to do so now.
If you did register your code at some point, in the EA App, in Origin, or on the old Sims 3 site, the EA account linked to the email you used at the time should have a copy of the game in your library. In that case, login to that account and download the game.
If your code reads as used but you can't find the account it belongs to, you'll need to contact EA customer support for help. Take a photo showing the disc, its case, and the product code (the one that's not working); you can upload this photo when you submit the help request.
https://help.ea.com/en/customer-care/
I would strongly recommend live chat rather than email. If you don't see the option, choose a slightly different category of issue.