This line began ruling Russia from 1762 to 1917 .
This line succeeded them and ruled Imperial Russia from 1762 to 1917 .