 The prosperity of the town came from agriculture, clothmaking and trade.It was located on the trade route connecting Poznań and Szczecin, and despite its annexation from Poland, it still had strong ties with Greater Poland.After the Thirty Years' War (1618–1648) many Poles settled in the town, and until 1660 local merchants were exempt from tariffs in trade with Poland.