Middleton, Charles, Earl of Middleton, Secretary of State