In the late Spring of 1745, a joint force of Saxons and Austrians that had crossed the mountains to invade Silesia. After allowing them across, Frederick pinned them down and defeated them at the Battle of Hohenfriedberg on 4 June 1745. Pursuing the Austrians into Bohemia, Frederick caught the enemy on 30 September 1745 and delivered a flanking attack on the Austrian right wing at the Battle of Soor, which set the Austrians to flight. Frederick then turned towards Dresden when he learned the Saxons were preparing to march on Berlin. However, on 15 December 1745, the Saxons were soundly defeated at the Battle of Kesselsdorf by Prussian commander Leopold of Anhalt-Dessau. After linking up his army with Leopold's, Frederick occupied the Saxon capitol of Dresden, forcing the Saxon Elector (and King of Poland) Augustus III to capitulate.