Shaitaan says : “If you miss him now , you will never catch him again….” – Ibn al Jawzi رحمه الله
When death befalls someone, he should know that it is an hour of serious suffering because it is a moment of severe pain, when he is leaving all objects of love, his loved ones, and to all that the horror of the throes of death and fear of where his wealth go. Then Shaitaan comes and attempts to have the slave [of Allaah] become discontent with his Lord, he tells him ‘Look at you! What made you die? Is it painful? You are leaving your wife, your children and you will be laid under the ground? So he might cause him to become discontent with his Lord, hating Allaah’s decree, making him say things that include any kind of objection, or he might make him unjust in his will, giving some of the inheritors preference over others, to on and so forth. In this case, we need to cure the whispers of Shaitaan and cure the self .
Abu Dawood reported from Abu al-Yusr (رضي اللّه عنـه) that the Prophet (صلّى اللَّهُ عليه وسلّم) used to say,
أَعُوْذ بكَ أْن يَتَخَبـطَنيَ الشيطَانَ عِنْدَ المَوْت
‘Aoozu bika ay-yatha khabbathaniyash Shaitaana indal Mawth’
“I seek refuge in You that Shaitaan flounders me at death.” 
In that minute Shaitaan tells his assistants,
“If you miss him now [i.e. you do not succeed to lead him astray before he dies], you will never catch him again [i.e. you will never be able to deviate him at any other time].”
As for the cure for these trials we should first mention that whoever is mindful of Allaah while in good health, Allaah will protect him when he is ill, and whoever observes Allaah in his thoughts, Allaah will protect him when he moves his bodily parts.
 Reported by Abu Dawood 1552-1553, al-Nasa’i [8:283] through the chain of Afla’ Mawla (emancipated slave) of Abu Ayyub from Abu al-Yusr that the Prophet (صلّى اللَّهُ عليه وسلّم) used to pray, “O Allaah! I seek refuge in you from dying under abolishment, not being deliberate, I seek refuge in you from drowning, from burning and from senility, I seek refuge in you that Shaitaan flounders me at death, I seek refuge in you that I die while escaping from fighting for Your sake and I seek refuge in you from dying because of a sting.”
“His seeking refuge in the ‘floundering of Shaitaan at death’, that is if Shaitaan seizes him when he leaves this world, preventing him from repenting or hinders him from mending his affairs, leaving an injustice or he makes him despair from the mercy of Allaah or makes him hate death or be sorry for this life, so he becomes discontented with Allaah’s decree in dissolution, going to the hereafter, so one has a bad end and he meets his Lord while he is discontented with Him.
It was narrated that the Shaitaan is never tougher on a man as in death and he tells his assistants: ‘Take this person! if you miss him today you will never catch him again.’ We seek refuge in Allaah from his evil, we ask him to bless our death and to have a good end.”
Source: from the Book “Disciplining the Soul” by Ibn al Jawzi رحمه الله