This has been a problem I have experienced recently. After three months (They moved quick) of a neighbors kids harassed our dogs I noticed our dogs would bark at people. Of Course, there are certain circumstances where you want your dog to bark at strangers. For example, if you have a unwanted person in your home, you will want your dog to alert you to their presence or send them off due to their presence. You do not want your dog to be welcoming to everyone without exceptions, but it is also important that they not view all strangers as intruders.
TEACH YOUR DOG TO BARK AND TO STOP BARKING ON YOUR COMMAND
Controlling your dog's vocalization with "speak" and "quiet" commands is an important part of basic training. Expose your dog a stimulant that makes them bark. Give your dog the "speak" command. Let them bark, then offer praise and a treat. Repeat until your dog is able to speak on command. Next, you will teach the "quiet" command in much the same way, namely, by offering treats, using a clicker, and praise when they do stop barking. Repeat until your dog understands exactly what you want them to do.
To help them introduce the commands with strangers, introduce your dog to a stranger and issue the "speak" command followed by the "quiet" command.
REWARD CALM GREETING BEHAVIOR
You can reward calm behavior when meeting strangers by gradually getting your dog accustomed to new people. Arrange a situation where your dog is exposed to strangers. The more, the better. Have them give your dog treats. This will help to make furry friend be friendlier and less likely to bark at unfamiliar people.
Be sure to keep how your dog feels in mind during these exercises. For example, if your dog is barking because they are excited or over-stimulated, these training sessions are a great way to control the barking. If your dog is barking out of fear you don't want to force them into an overcrowded environment because this can lead to aggressive behaviors due to fear.
MAKE SURE THAT YOUR DOG GETS ADEQUATE EXERCISE
Tired dogs are less likely to desire excessive barking. Excessive and inappropriate barking is often the result of stress from getting too-little exercise. More walks or even agility training may be necessary.
STAY CALM AROUND STRANGERS
Your dog can interpret your emotions very well and they are likely to reflect it. As irritating or frustrating as a noisy dog can be, expressing your irritation or frustration can make the situation worse as your dog may adopt your feeling and express it with even more barking. It is important to compose yourself before correcting your dog and to communicate in a calm and measured voice.
Raising your voice at your dog to stop barking can sometimes cause them to continue barking because now they feel that you are engaging in the bad behavior situation with them.
Dogs bark at people and animals they do not know, this is normal; however, that instinct/desire to bark can be controlled. The steps above can help you to take control of how your dog reacts to strangers.