If you have a problem with a neighbor’s barking dog, first approach the neighbor to tell him there is a problem.
Owners sometimes do not realize their dog is causing problems because the dog may bark only when the owners are away from the house.
If your efforts do not achieve the desired results, then contact your local animal control office.
Do not try to correct the dog, give it attention or give it food to stop the barking as you will generally cause more problems.