Abu Jahal was among the disbelievers surrounding the house of Rasulullah (sallallahu ‘alaihi wasallam) that night. While they were waiting outside the door, he mockingly said to the others in the group, “Muhammed (sallallahu ‘alaihi wasallam) claims that if you follow him in his religion, you will one day become the rulers of the Arabs and non-Arabs. He says that after you die, you will be resurrected and you will be given beautiful gardens. He says that if you do not follow him, you will one day suffer death at his hands, and after your death, you will burn in hell.”
As Abu Jahal said this, Rasulullah (sallallahu ‘alaihi wasallam) came out of his home and said, “Yes! This is what I say, and you (O Abu Jahal) will be one of the people burning in the fire.”
Rasulullah (sallallahu ‘alaihi wasallam) then took a handful of sand, and while passing by the disbelievers, scattered it on their heads, reciting the opening verses of Surah Yaseen. Rasulullah (sallallahu ‘alaihi wasallam) recited until the verse:
وَ جَعَلۡنَا مِنۡۢ بَیۡنِ اَیۡدِیۡہِمۡ سَدًّا وَّ مِنۡ خَلۡفِہِمۡ سَدًّا فَاَغۡشَیۡنٰہُمۡ فَہُمۡ لَا یُبۡصِرُوۡنَ
And We have placed a barrier in front of them and a barrier behind them, and (thus) they are encircled by Us; so they do not see. (Surah Yaseen v. 9)
Allah Ta‘ala made it such that the disbelievers were completely blinded and were unable to see Rasulullah (sallallahu ‘alaihi wasallam). In this way, Rasulullah (sallallahu ‘alaihi wasallam) was able to leave completely undetected.
(Rowdh-ul-Unf 2/309)