Short answer: Open the Dose Track Pro screen (the PRO? badge at the bottom of Settings) or the upgrade screen, tap the small Have a code? link, type your code and tap Apply code. What happens next depends on your phone.
Before you start: You need a code someone gave you. The link is hidden once you already have Pro.
After a code is used, the link changes to show the code and the date your free time runs until.
Want your own code to share? See the Dose Track partner program.