 It became property of the Swedish King, in 1658 as a result of the Treaty of Roskilde.Between 1667 and 1675, the citadel was expanded with extensive bastions.On 2 August 1676, during the Scanian War, the commandant Hieronymus Lindeberg surrendered himself and the castle to a Danish army unit.