Don't withhold HOA dues--this had nothing to do with the HOA, and if you fail to pay your dues, you could be sued by them, or have them put a lien on your property.It is the seller who was obligated to either make sure there was a Certificate of Occupancy or, at  minimum, to disclose up front (before you signed the contract) that there was none, so you could decide whether or not to make an offer. A failure to disclose a known material or important fact like this can be fraud; fraud can provide a basis for recovering compensation, such as the cost(s) involved in getting a C of O. You should therefore be able to sue the seller based on fraud for your costs or losses.