Flies are easy to kill, but not all that easy to treat for. Let me explain the distinction:
If you spray even a low-toxic non-residual spray directly on a fly, it will be incapacitated fairly quickly, fall to the ground and spaz out until it dies. Not so a cockroach. Roaches need to be treated with a variety of sprays and/or baits. (As a professional, I prefer baits; they’re non-repellant and use the insect’s natural instinct against them.) But baits take time, and while sprays will kill them eventually, there needs to be prolonged contact with a residual insecticide applied in the areas where their traffic is highest. Roaches are just hardier insects.
But the treatment is more difficult for flying non-social insects such as flies. With bees and wasps, since they have a specific nest, treating the nest will solve the problem. But flies don’t nest, they have no social order. So you can’t treat just one area. While roaches are not social insects, most species of roach don’t rely on flight as their main means of locomotion. Their habits are also to hide in dark areas, such as cracks and crevices under and behind cabinets, under sinks and baseboards, etc. And you can often see either the insects themselves, or their droppings, which look like small black pellets, not unlike ground pepper. When you see this crap in or around a specific area, you can target that area with an application of bait, secure in the knowledge that the roaches will come across it and eat it.
Fogging an entire room is a drastic approach. (Not to mention a little dangerous; not only could you and/or your family and pets possibly breathe in toxic chemicals, but you could blow up your house. People don’t appreciate the fact that these things have a flash point and that a stove’s pilot light could cause the fumes to ignite.) And it will kill only those flies that fly through enough of the stuff to kill them. Any that are unhatched or manage to avoid the spray will still be around.
There are fly baits, but my understanding of them is that they’re used mostly in locations such as barns or grain storehouses, not in residences or most businesses.
This leaves us with traps such as flypaper strips, or a mechanical device called a fly light that uses an ultraviolet lamp to lure flying insects in, then traps them with a glueboard inside the back of the lamp housing. Fly lights are generally used near the kitchen doors of restaurants, where flies are most likely to gain access. They are preferred over the zappers because zappers can result in bug guts and pieces being flung far and wide. Bon apetit.
The only other method of battling flies is to be pro-active and make sure you don’t have dead birds or animals in your garden, your crawlspace, your attic, or your chimney. Flies lay their eggs on dead carcasses. Remove the host, and you remove (or at least reduce) the likelihood of a fly infestation. Remember, 75 - 90% of effective pest control is sanitation.