In 1877 the British Army took control of Transvaal, and Kruger became the leader of the resistance (the people who wanted to fight British control). On 30 December 1880, the government of the South African Republic (Transvaal) elected (chose) him to be president. In 1881 Kruger negotiated (talked with the enemy) to agree the peace.