Do a search for separation anxiety - then work at the root of the problem, the shock collar will probably do no good without working on WHY he's barking.