 He was nearly stripped of his office, but the favor of the king and the large amounts of money he was remitting to Spain worked in his favor.His property in Catalonia was, however, confiscated, but was returned to his heirs in 1714.He did reach an agreement with the merchants, whereby in return for their financial help he would expel the French from the viceroyalty.