The act of resigning or giving up a legitimately held ecclesiastical office, dignity, or benefice. In principle every ecclesiastical office or rank may be resigned by the one who holds it. To be valid, however, the abdication must be totally voluntary and free from simony. Papal abdication can be made into the hands of the College of Cardinals, since they have the right to elect a successor. Six popes actually abdicated: Marcellus, Liberius, Benedict IX, Gregory VI, St. Celestine V, and Gregory XII. Pope Pius VII signed a conditional abdication in 1804 before he set out for France to crown Napoleon. The condition was that he would automatically resign the papacy if he were made a prisoner in France.