Maria Theresa started her 40-year reign when her father, Emperor Charles VI, died in October 1740. Charles VI paved the way for her accession with the Pragmatic Sanction of 1713 and spent his entire reign securing it. He neglected the advice of Prince Eugene of Savoy, who believed that a strong military and a rich treasury were more important than mere signatures. Eventually, Charles VI left behind a weakened and impoverished state, particularly due to the War of the Polish Succession and the Russo-Turkish War (1735–1739). Moreover, upon his death, Saxony, Prussia, Bavaria, and France all repudiated the sanction they had recognised during his lifetime. Frederick II of Prussia (who became Maria Theresa's greatest rival for most of her reign) promptly invaded and took the affluent Habsburg province of Silesia in the seven-year conflict known as the War of the Austrian Succession. In defiance of the grave situation, she managed to secure the vital support of the Hungarians for the war effort. During the course of the war, Maria Theresa successfully defended her rule over most of the Habsburg Monarchy, apart from the loss of Silesia and a few minor territories in Italy. Maria Theresa later unsuccessfully tried to recover Silesia during the Seven Years' War.