Ohio’s attorney general resigned Wednesday under threat of impeachment because of a sexual harassment investigation in his office and his extramarital affair.

Attorney General Marc Dann said at a news conference that he had to resign to preserve the ability of the office to carry out the priorities he established.