Place him in a different room, when he misbehaves. Give him attention and reward him only when he behaves and does not bark, or go nuts when your doing those things. He will learn that good things happen when he does not act like that. Be very consistent too, and take action as soon as he misbehaves.