After being educated at Cracow, he made the grand tour with his brother Mark and returned to Poland in 1648.
Only his superb strategy and the heroic devotion of his lieutenants - notably the converted Jew, Jan Samuel Chrzanowski, who held the Ottoman army at bay for eleven days behind the walls of Trembowla - enabled the king to remove "the pagan yoke from our shoulders"; and he returned to be crowned at Cracow on the 14th of February 1676.
Having studied at Ingolstadt, Vienna, Cracow and Paris, he returned to Ingolstadt in 1507, and in 1509 was appointed tutor to Louis and Ernest, the two younger sons of Albert the Wise, the late duke of BavariaMunich.
The churchmen headed by Stanislaus Szczepanowski, bishop of Cracow, took the side of the nobles, whose grievances seem to have been real.
At Rome too he obtained a canonry attached to Cracow cathedral, and on his return to Poland in 1755 threw himself heart and soul into the question of educational reform.