The king refused to allow Israel to pass through his border. He gathered his army and attacked Israel in the wilderness.