Training your dog can take a while. There are tools you can use to help you with the process though. This Outdoor Bark Control Trainer trains your dog to stop barking without causing any pain. Whenever it detects parking, it emits an ultrasonic tone to help your dark associate barking with it and stop its bad habit. The tone is inaudible to most humans.
The device has a digital timer that can be programmed to turn it on and off at specific times. It is weatherproof and looks like a birdhouse. The only caveat is this might not work for every dog.