He was junior emperor until 1078, when Michael VII was replaced by Nikephoros III Botaneiates. Because Constantine was not made junior emperor under Nikephoros III, his betrothal to Olympias, the daughter of Robert Guiscard, was broken, which Robert Guiscard used as a pretext to invade the Byzantine Empire. John Doukas forced Nikephoros to abdicate to Alexios I Komnenos in 1081, and shortly after Alexios elevated Constantine to junior emperor under himself.