There are different codes on an invoice and this error message can indicate any of them.
The best way to find out which code the message is referring to is to click "OK" to the message and then the un-registered code will be highlighted.
If Item code is highlighted then it means that there is no Item with this code in the Items register.
If Customer code is highlighted then it means that there is no customer with this code in Contacts register.
If nothing is highlighted then it means there is no Tax Code (T-Cd). To set up the tax codes go to Settings and then Tax Codes.