Legend has it that Olomouc was founded by Julius Caesar. It later became a major seat of administrative power when Moravia and Bohemia were united in the 11th century, then a bishopric in 1063. Olomouc has the bearing of a capital city, and was the Moravian capital from the 12th century until it was occupied and looted by Swedish troops between 1642 and 1650. It has been the seat of the metropolitan archbishop of Moravia since 1777. Industrialisation passed it by until well into the 20th century.