If you contact the local Board of Realtors they will help you determine what ethical issues, if any, may have been violated and they will assist you in filing a complaint. Realtors are a self-policing organization. Please be aware that if you file a complaint that you may be expected to attend a hearing, so that your matter can be investigated fully.
It is possible that the listing agent had a buyer who initially performed on the contract but maybe his/her financing was turned down, so the listing status went back to "active" until the buyer could secure alternate financing. Likewise, the home might have had inspection issues that the seller initially refused to take care of and the status would have changed if the seller ultimately changed their mind about doing repairs to get the house sold. (In other words, sellers sometimes refuse to do repairs until they figure out that EVERY buyer will expect the repairs to be done else the home wont sell!) Or, there's always the chance that the listing agent is working with a favored buyer - possibly a past customer - and that buyer is being given preferential treatment. To the seller a bird in the hand may be worth 2 in the bush. Remember the listing agent works for the seller, not you, and apparently the seller is pleased with their agent's performance.
My opinion is that you probably should select a different home, as the message seems clear that this one isn't going to go your way. It does not appear that there are ethical violations from what you said, just negotiation issues that are typical. Good luck!... more