After the House of Sponheim had become extinct in 1269, the Carinthian duchy was acquired by King Otakar II of Bohemia, later it passed to the Meinhardiner Count Meinhard II of Tyrol. His granddaughter Countess Margaret in 1335 finally lost Carinthia to Duke Rudolf IV of Austria from the House of Habsburg, whereafter it was incorporated into the dynasty's Inner Austrian lands and ruled by stadtholders. In 1362 Rudolf granted the Sankt Veit citizens the permission to hold the annual "Wiesenmarkt" fair, which is arranged up to today as one of the oldest festivals in Central Europe. Its town hall dates from 1468 and the present-day ducal castle from the 15th to 16th century.