To connect your Kindle to your credit card, first:
1. it must be registered to your Amazon account, and
2. it must be online and connected to WiFi, and
3. it must be in Manage Your Content And Devices, and
4. from there you go to Settings, then to
Edit Payment Methods
then choose the credit card entry already entered there, if it just needs updating, and verify and/or correct (as needed) the details there. Perhaps if your credit card expired in 9/2017, on September 1st, then all you need to do is correct to the newly issued credit card's new expiration date.
Save that change, and you should have cured the problem and be capable of buying books on your Kindle again.
Let me know if (or, if not) that helps answer your question, please.