Dharmawangsa, stylized regnal nameSri Maharaja Isyana Dharmawangsa Teguh Anantawikramottunggadewa of the Isyana dynasty, was the last raja of the Kingdom of Medang, who reigned from 990–1016 CE. He also known by his posthumous nameWijayamreta Wardhana, which means "powerful in glorious death", which refer to his fight to the death.
Reign
He succeeded SriMakutawangsa Wardhana. Dharmawangsa was the patron of the translator of the Mahabharata text into Old Javanese. Dharmawangsa was either the son or son-in-law of Sri Makutawangsawardhana, preceding King of Medang and grandson of Mpu Sindok. Dharmawangsa conquered several areas, including Bali, and established a colony in West Kalimantan. Dharmawangsa's sister, Princess Mahendradatta, married Udayana, Raja of the Warmadewa Dynasty in Bali, and had a son, Airlangga. In the year 990, Dharmawangsa launched a naval invasion on Sriwijaya in Sumatra and unsuccessfully attempted to capture Palembang, as Sriwijaya repelled the invaders. Dharmawangsa's invasion is mentioned by both ambassadors to China in 992.
Death
In 1016, Srivijaya launched a retaliation attack and destroyed the Watugaluh Palace in Java. Srivijaya forces assisted the lesser king Haji Wurawari of Lwaram to revolt, attacked and destroyed the Medang Palace, killing Dharmawangsa and most of the royal family. This sudden and unexpected attack took place during the wedding ceremony of Dharmawangsa's daughter, which rendered the court unprepared and shocked. Dharmawangsa follows kshatriyacode of honor, valiantly defend his court to his death. For this he was honored in his posthumous name Wijayamreta Wardhana which means "powerful in glorious death". This calamity was recorded in Javanese account as the pralaya the death of the Mataram kingdom. With the death of Dharmawangsa and the fall of the capital, under military pressure from Srivijaya, the kingdom finally collapsed and fell to chaos. There was further unrest and violence several years after the kingdom's demise. Dharmawangsa's heir and nephew, Airlangga, son of Mahendradatta and Udayana, was aged only 16 at the time. However, he escaped the invaders and went on to become founder of the Kahuripan Kingdom, successor of the Medang Kingdom.