Wikipedia: Papal Election 
Extensive article on historical and modern procedures of electing a new pope.
http://en.wikipedia.org/wiki/Papal_electionUniversi Dominici Gregis 
By John Paul II. Apostolic Constitution promulgated on 22 February 1996. Defines the procedure of the election of his successor.
http://www.vatican.va/holy_father/john_paul_ii/apost_constitutions/documents/hf_jp-ii_apc_22021996_universi-dominici-gregis_en.html
Wikipedia: Papal Election 2005 
Discusses the selection of the papal successor to Pope John Paul II.
http://en.wikipedia.org/wiki/Papal_election%2C_2005