
Emotions are not formed by situations.
They're formed by how we interpret situations.
If we want to be happy people, we will want to learn the skill of interpreting even our most painful situations in a positive way.
We see this way of thinking in the Rebbe's teachings about the Three Weeks - from the 17th of Tammuz being called "Tov Tammuz" to the idea that the Third Beis HaMikdash is the culmination of a process, not merely a replacement for what was lost.