political projects. As she avoided the later capture of the Spanish royal family, she attempted to take charge of the viceroyalty as regent. This political project, known as Carlotism, sought to prevent a French invasion of the Americas. A small secret society of criollos, composed of politicians such as Manuel Belgrano and Juan José Castelli, and military leaders such as Antonio Beruti and Hipólito Vieytes, supported this project. They considered it an opportunity to get a local government instead of a European one, or a step towards a potential declaration of independence. The project was resisted by Viceroy Liniers, most peninsulars, and some criollos, including Cornelio Saavedra and the lawyers Mariano Moreno and Juan José Paso. They suspected that it concealed Portuguese expansionist ambitions over the region. The supporters of Carlota Joaquina intended her to head a constitutional monarchy, whereas she wanted to govern an absolute monarchy; these conflicting goals undermined the project and led to its failure. Britain, which had a strong influence in the politics of the Portuguese Empire, opposed the project as well: they did not want Spain split into several kingdoms, and considered Carlota Joaquina unable to prevent this. Prelude Liniers government After the British invasion of 1806, Santiago de Liniers successfully reconquered Buenos Aires. The population did not allow Rafael de Sobremonte to continue as Viceroy. He had escaped to Cordoba with the public treasury while the battle was still in progress. A law enacted in 1778 required the treasury to be moved to a safe location in the case of a foreign attack, but Sobremonte was still seen as a coward by the population. The Royal Audiencia of Buenos Aires did not allow his return to Buenos Aires and elected Liniers, acclaimed as a popular hero, as an interim Viceroy. This was an unprecedented action, the first time that a Spanish viceroy was deposed by local government institutions, and not by the King of Spain himself; King Charles IV ratified the appointment at a later time. Liniers armed the entire population of Buenos Aires, including criollos and slaves, and defeated a second British invasion attempt in 1807. The Liniers administration was popular among criollos, but not among peninsulars such as the merchant Martín de Álzaga and the Governor of Montevideo, Francisco Javier de Elío. They requested the Spanish authorities appoint a new viceroy. In the wake of the outbreak of the Peninsular War, de