Gordon Brown served as Chancellor of the Exchequer of the United Kingdom from the Labour Party's 1997 general election landslide victory on 2 May 1997 to 27 June 2007, when elevated as Prime Minister of the United Kingdom following the resignation of Tony Blair. Brown was the longest-serving Labour Party Chancellor, and his tenure as chancellor was the second-longest continuous period of office of any Chancellor, surpassed only by Nicholas Vansittart two centuries before.