World events thereafter moved against the Conservatives. Controversial wars in Afghanistan and South Africa undermined his public support. He angered British farmers by refusing to reinstitute the Corn Laws in response to poor harvests and cheap imported grain. With Gladstone conducting a massive speaking campaign, his Liberals defeated Disraeli's Conservatives at the 1880 general election. In his final months, Disraeli led the Conservatives in Opposition. He had written novels throughout his career, beginning in 1826, and he published his last completed novel, "Endymion", shortly before he died at the age of 76.