It is narrated from Sayyiduna Suhayb (may Allah be pleased with him) that the Messenger of Allah (peace and blessings be upon him) said: "For the believer there is good in every state, and this is not so for anyone except the believer. If something good comes to him, he thanks Allah, and there is reward for him in return. If hardship befalls him, he is patient, and in that case too there is reward for him. In short, every decree of Allah Almighty is good for the Muslim."
Hadith Referenceالسنن الكبرى للبيهقي / كتاب الجنائز / 6554