Margrete’s victory at Asle had won for her most of Sweden. Only Stockholm, dominated by its strong German element, remained faithful to Albrecht and even organised a massacre of ‘treacherous’ Swedes (Kapplingemorden, spring 1389). Margrete appears to have made Albrecht’s release dependent on his abdication. Consequently, his native land, Mecklenburg, declared its ports open to everybody who wanted to fight Denmark; Rostock and Wismar had to follow the duke’s policy. Letters of marque were granted by the dukes or the cities to privateers, who took the name of Vitalienbruder. The aim of this naval guerrilla warfare was to free Albrecht and to revictual Stockholm.
Attempts were made to resolve the problem by diplomatic means, and in June 1395 agreement was finally reached at Lindholm. Albrecht and his son were to be freed for a period of three years, during which time Stockholm would be held by a group of Hanseatic towns. When the three years had expired, Albrecht and his son, who were not obliged to renounce their claims to Sweden, would have three options. If they surrendered Stockholm to Margrete, they could have ‘eternal’ peace with her; if they paid a ransom of 60,000 marks of silver, they would be free to declare war on Margrete after a delay of one year; finally, if they agreed to re-enter captivity, this time span could be reduced to nine weeks.
In the meantime, Visby became an important base for the Vitalienbruder, whose activities in the western Baltic were curtailed as a result of the Treaty of Lindholm. Having lost their last veneer of legality, they operated after 1395 in the North Sea — they had already made a raid on Bergen at Easter 1393 — and in the eastern Baltic. In order to pacify these waters, the Teutonic Order and the Prussian towns occupied Gotland in 1398, with the desired effect: by 1400 the Vitalienbruder had disappeared from the Baltic. At the same time, the Hanseatic towns and Margrete cleared their respective parts of the North Sea of the remaining pirates.
According to the Treaty of Lindholm, Stockholm was to be returned to Sweden after three years, if Albrecht preferred to stay at liberty. It was equally important in another respect. Were Margrete to die before the three years had elapsed, Erik, her adopted son, would take over her rights. Already designated king of Norway in 1389, he was acclaimed in Denmark and Sweden in 1396. Margrete continued as regent for another year, until Erik came of age and was crowned at Kalmar in June 1397 at a ceremony recognised as valid by his three kingdoms. It was thus indicated that the Union was to be more than a union of crowns.
At the same time as Erik’s official recognition as future king of Sweden and Denmark the foundations of the domestic policies of both kingdoms for the coming years were established by statute. The texts express concern for the personal security of the subjects. In Denmark, the construction of private fortresses was forbidden; while in Sweden, those built after Albrecht’s accession to the throne (1363) were to be demolished, if Margrete or Erik desired it. Attempts were also made to reduce exemptions from taxation on land claimed by the Church or by men whose title to aristocracy could be legitimately challenged. Moreover, considerable areas of land were reclaimed for the crown by the scrutiny of title-deeds.
Two documents inform us about the negotiations held after Erik’s coronation in order to organise the Union. The so-called ‘Coronation charter’ shows that Erik had been recognised in the three countries and crowned as their legal king. Consequently his subjects promised to do their duty towards their lord and ruler, as he was to do his duty towards them. Finally, Margrete received discharge for her administration.
The ‘Coronation charter’ provided few rules for the future government of the three kingdoms; only the coronation itself gave them the legal basis for any sense of unity. To remedy the situation, a group of Margrete’s closest collaborators from the three countries drafted the ‘Union charter’, which, however, was never ratified. After Erik’s death, the three countries were to elect one of his sons; however, if a king left no children, the ‘councillors and men’ of the three countries were to elect a new king. The right of succession was thus limited to the male children of the preceding king, which represents a compromise between the elaborate Norwegian rules of succession and the Swedish and Danish system of election within the royal family. Each country was to be governed according to its own laws both in home and foreign affairs; however, if one country got involved in war, the two others were to come to its assistance. Proscription in one country should be valid in the others as well. Moreover, the king should always have a few councillors from each country at his court, in case urgent decisions had to be taken. Finally, Margrete’s possession of her dower and other estates was confirmed.
The queen realised the good use she could make of the Church and its personnel. To have a loyal collaborator appointed to a bishopric by papal provision meant, in most cases, the creation of a solid support of governmental policy within the decision-making body of the country in question. Thus Peder Jensen Lodehat, who had begun his career as Margrete’s clerk, was appointed to the Swedish see of Vaxjo in 1380. In 1387 he took over the bishopric of Aarhus (Denmark), which, eight years later, he exchanged for the richest Danish diocese, Roskilde, where he served until his death in 1416. Economic reasons, too, told Margrete to collaborate with the Church. From it she could obtain loans, if money was urgently needed; in this respect, St Mary’s church at Oslo and the cathedral of Roskilde served her as banks. The loans were often paid back either by cession of part of the regalia to the ecclesiastical creditors or by donations to the Church, thus adding a spiritual dimension to the prosaic settling of accounts.
In foreign affairs, the government of Margrete and Erik saw the main issues as the settlement of the succession and the restoration of the Union’s territorial integrity. In 1406, Erik married Philippa, daughter of Henry IV of England. Her sister had married a son of Ruprecht, king of the Romans, and so became sister-in-law to Erik’s sister, Catherina, when she married Ruprecht’s younger son, the count palatine, Johann, in 1407.
Stockholm was returned to the Swedish government in 1398, but in the same year, Margrete and Erik lost Gotland to the Teutonic Order. In face of growing tension between Poland—Lithuania and the Teutonic Order, the latter became more inclined to a compromise with Margrete and Erik about the surrender of the island, and in November 1408 the last Prussian occupants left.
The Danish government had found a modus vivendi with the counts of Holstein, as in 1386 Gerhard VI had been enfeoffed with the duchy of Schleswig. At his death in 1404 he left his widow, Elizabeth, and three sons, all minors. Elizabeth needed money, which Margrete was ready to lend her against security in land. In this way the queen won control over large parts of the duchy, where the bishop of Schleswig was a staunch supporter of Margrete and Erik. In 1409 the pro-Holstein part of the aristocracy realised that the objective of Margrete and Erik was the acquisition of Schleswig for Denmark and consequently its separation from Holstein. In order to thwart these attempts they revolted, and war ensued. By negotiating a five-year truce (1411), Margrete succeeded in bringing the hostilities to an end; on Erik’s behalf, she received the oath of allegiance from Flensburg, the largest town of the duchy, but she was to die of the plague only a few days later (28 October 1412).