And when Napoleon crowned himself as emperor the church was miserable

Can you repeat this sentence, but add in punctuation?
And when Napoleon crowned himself as emperor the church was miserable.