Hisnul Muslim 218

What to say upon receiving pleasing or displeasing news

(1)الْحَمْدُ للَّهِ الَّذِي بِنِعْمَتِهِ تَتِمُّ الصَّالِحَاتُ(2)الْحَمْدُ للَّهِ عَلَى كُلِّ حَالٍ

Alhamdu lillaahil-lathee bini'matihi tatimmus-saalihaat.(1)Alhamdu lillaahi 'alaa kulli haal.(2)

When something happened that pleased him say: "Praise is to Allah Who by His blessings all good things are perfected".(1)And if something happened that displeased him say: "Praise is to Allah in all circumstances".(2)