These should be done seperately, otherwise you will confuse your dog.
Knock on the door at random times, no bark, no treat. Continue this until you feel that he has it down: knock, bark, treat and praise. Do only this part for as long as needed. Once he has learned this, move on to no-knock, bark, squirt of water. 10-15 (adjust this time as need... at first you may only want to ask him for quiet for 5) minutes of quiet, with no-knock, treats and praise.