I have got some invoices, that had the wrong state in magento, but the right status "paid" in the payment extension. The reason was a bug in the extension.
So I fixed that by setting the state of these invoices to "2" for paid in sales_flat_invoice and sales_flat_invoice_grid (yes, not the best way to do it...).
Result:
Now the invoices have the right state, they are paid, but there is now button for credit memo available.
Question:
What is missing?
What are the requirements to show up the credit memo button for invoices?
I am using Magento CE 1.9.2.1.