If you see someone afflicted by misfortune, recite:
الْحَمْـدُ للهِ الّذي عافاني مِمّا ابْتَـلاكَ بِهِ، وَفَضَّلَـني عَلى كَثيـرٍ مِمَّنْ خَلَـقَ تَفْضـيلا
Praise is to Allah Who has spared me what He has afflicted you with, and preferred me greatly above much of what He has created.
At-Tirmidhi 5/493,4. See also Al-Albani, Sahih At-Tirmidhi 3/153.