Is it true that some people feel that they will die 40 or 60 days before they actually die? If it is true, in what form they feel? By dreams, visions, or just have strong feeling? What should a person do if he has this feeling and it bothers him a lot and makes him worried and scared all the time?
Praise be to Allah, the Lord of the World; and may His blessings and peace be upon our Prophet Muhammad and upon all his Family and Companions.
In reality, there is no evidence (in the Qur'an or Sunnah) that proves a human being's becoming aware of his/her death nearness, forty/sixty days before breathing his/her last.
From a practical point of view, most people do not feel such a state. Maybe there are some states in which a person becomes aware of closeness of his/her death, but such a case is not restricted to forty or sixty days. Rather, most such cases come in the same day, one or two days before one's death.
Some people are afflicted with abnormal anxiety. So, they think of nearness of death and the ghost of fearing death controls them. This state is from the devil in order to sadden a believer and drive him a way to despair. Thus, we are required to be ready to meet Allah, The Great and Al-Mighty, and to do more good deeds since death comes suddenly.
However, despair and fear are fruitless in this concern. Allah's fate is sure, so it is our duty to repent and haste in doing good deeds and to avail ourselves of the opportunity in righteous actions. We advise you to increase Zikr of Allah (Allah's remembrance), reading the Qur'an, and commitment to perform the five daily prayers in congregation. Such above-mentioned points, Insha Allah, will help you treat and drive away despair and fear.
Allah knows best.
You can search for fatwa through many choices