The best way to get rid of flies is to keep your house extremely clean and sanitary. Wash dirty dishes as soon as you can. Vacuum and dust frequently. Also, make sure your trash has a lid on it. If the flies are still hanging out at your house, you can always use a fly swatter on them.