faced his enemy with a powerful army, but in a heroic battle, he lost ground. The Punjab
lay at the feet of Mahmud.
In A.D. 1009, he
plundered the temple of Nagarkot. In A.D. 1011, he desecrated the shrine of Chakrasvamin
at Thaneshvar. Anandapala, however, was still a rallying centre of resistance from Lahore.
In A.D. 1012 he died and was succeeded by his son Trilochanapala. Mahmud, in spite of a
treaty with his father, attacked him. Trilochanapala fought with unflinching heroism.
"Trilochanapala causing floods of blood to pour in
battle resembled Shiva (trilochana) when sending forth the fire which burns the world at
the end of the Kalpa."