How do you get a real estate commission returned to you if your realtor did not do their job?

you go to the real estate board (in the local yellow pages), make a complaint, and also make a complaint with the real estate company the agent works for. then you contact a real estate lawyer and get his opinion.