There are many ways in which you can stop dogs from pooping in your yard, including buying the right products, using water to keep them away, and making homemade sprays. Before you concoct any DIY sprays, double-check to see that all the ingredients are safe for dogs.