I get the 40lb bag of food grade DE and 20lb bags of Stall fresh sweet PDZ from our local feed store. Sprinkling DE on wet or stinky spots dries them, helping with the smell that attracts the flies. I have read that the flies that crawl over or through it will die several hours later as they dehydrate. Flies also breed in wet moist areas, so keeping problems spots dry prevent maggots.
The sweet PDZ is something I'm addicted to. There I've said it. I LOVE the stuff. Don't judge me please. Sweet PDZ dries but also absorbs ammonia. Bad smells the flies are attracted to. But wait, there's more! It releases that amonia as slow release nitrogen fertilizer! I get the granular type, its similar to kitty litter in texture. Its a natural mineral and harmless to animals. I sprinkle the Sweet PDZ in the heavily pooped areas around the water, and favorite hang out spots. I use it around my patio, which I'm constantly washing off. The granular texture also improves my clay soil. I even sprinkle it in my artificial turf. My quail sand is now about 50/50 sand and PDZ. It never degrades, breaks down or goes away, it just keeps working. For my birthday, I want sweet PDZ, just bags of it.
Also those stinky water bag fly traps from home depot type stores that lure and drown flies scattered about.