Balak sent messengers to Bilam saying that he should come and help, "Va'agarshenu min ha'aretz." The Midrash comments, "Lo haya mivakesh elah l'garsham she'lo yikansu la'aretz." All Balak wanted was to keep the Jews out of Eretz Yisrael.
Balak would fit right in today with the progressives, the EU, the Reform. "I'm not anti-Semitic," he would say. "I'm just anti-Zionist."
Balak made the fundamental error of thinking that Judaism is a religion and not a nationality. A religion stakes no claim to a country. You can practice whatever avodah zarah you like any place in the world and its all the same. Not so Judaism. Judaism without Eretz Yisrael is an incomplete Judaism (see Ramban in parshas Acharei Mos. See also the first Shem m'Shmuel on the parsha re: this Midrash).
Rashi writes that Bilam's donkey banging Bilam's leg into the wall three times is an allusion to the three regalim. Hashem was telling Bilam that he cannot beat a people that celebrates the three Yamim Tovim of the year.
Everyone asks (and we've discussed it before): why does the celebration of the shalosh regalim in particular signify that Bilam's efforts were doomed? Why is it more significant than any other mitzvah that we do?
Sefas Emes (5648 -- you really want to see this one inside) answers that on the shalosh regalim we make aliya la'regel and come together "ba'makom asher yivchar Hashem." We demonstrate the centrality of Yerushalayim, the centrality of the makom mikdash, to who we are as a people.
"Ki me'rosh tzurim er'enu u'migeva'os ashurenu…" Rashi explains that Bilam looked back and saw our roots, the Avos. The Sefas Emes reads the pasuk k'peshuto: Bilam looked out over the mountains and valleys of Eretz Yisrael, and when he looked out at the land, at its character, at its soul, what he saw was the character and soul of the Jewish people. He saw that we are one with the land.