In 1816, he took various European plants to Buenos Aires, where he was elected professor of natural history. He soon left his post, however, to explore the interior of South America. In 1821, he established a colony at Santa Ana near the Paraná for the specific object of harvesting and selling yerba mate. The colony was located in territory claimed by both Paraguay and Argentina; further, José Gaspar Rodríguez de Francia, dictator of Paraguay, "feared that Bonpland's success in cultivating "mate" would interfere with his own attempt to monopolize that business." The Paraguayans therefore destroyed the colony on December 8, 1821, and Bonpland was arrested as a spy and detained at Santa Maria, Paraguay until 1829. During his captivity, he married and had several children. He was given freedom of movement and acted as a physician for the local poor and the military garrison. At the same epoch, the Swiss naturalist Johann Rudolph Rengger also stayed in Paraguay: he was not allowed to cross the strictly guarded border, but was free to circulate pending the request of a special permit for each excursion.