In 1310, Emperor Henry VII arranged the marriage of his 14-year-old son John to Elizabeth of Bohemia, sister of the deceased King Wenceslaus III of Bohemia. The wedding took place in Speyer, after which the newlyweds made their way to Prague accompanied by a group led by the experienced diplomat and expert on Czech issues, Peter of Aspelt, Archbishop of Mainz. Because the Emperor had imperial Czech regiments accompany and protect the couple from Nuremberg to Prague, John was thus forced to invade Bohemia on behalf of his wife Elizabeth. The Czech forces were able to gain control of Prague and depose the reigning king, Henry of Gorizia, King of Bohemia, on 3 December 1310. The deposed King Henry fled with his wife Anne of Bohemia (the sister of John's wife) to his duchy (the Duchy of Carinthia). The coronation of John and Elizabeth to the Bohemian throne took place on 7 February 1311, making them hence King and Queen of Bohemia. The castle at Prague was uninhabitable so John made residence in one of the houses on the Old Town Square, and with the help of his advisors, he stabilized affairs in the Czech state. He thereby became one of the seven prince-electors of the Holy Roman Empire and – in succession of his brother-in-law Wenceslaus III of Bohemia – claimant to the Polish and Hungarian throne. His attempts to follow his father as King of the Romans failed with the election of Louis IV of Bavaria in 1314. Nevertheless, John later would support Louis IV in his rivalry with Frederick the Fair, King of Germany, culminating in the 1322 Battle of Mühldorf in which in return he thus received the Czech region of Egerland as a reward.