Sahih Bukhari Volume 9, Book 93, Hadith Number 642.

Narrated By ‘Ali : While the Prophet was in a funeral procession, he took a stick and started scraping the earth with it and said, “There is none of you but has his place assigned either in Hell or in Paradise.” They (the people) said, “Shall we not depend upon that (and give up doing any deeds)?’ He said, ” Carry on doing (good deeds) for everybody will find it easy to do such deeds as will lead him to his destined place for which he has been created.” (And then the Prophet recited the Verse): ‘As for him who gives (in charity) and keeps his duty to Allah…’ (92.5)