For example if Prophet Muhammad (PBUH) comes in a dream and says you will goto Heaven or any similar dream like that.So can a person get a good news of Jannah in dream or bad news of Jahannam in this life through a dream ?
There are certain ahadith speaking about seeing the Prophet in a dream. For instance:
مَنْ رَآنِي فِي الْمَنَامِ فَقَدْ رَآنِي، فَإِنَّ الشَّيْطَانَ لاَ يَتَخَيَّلُ بِي
Whoever has seen me in a dream, then no doubt, he has seen me, for Satan cannot imitate my shape.
مَنْ رَآنِي فِي الْمَنَامِ فَسَيَرَانِي فِي الْيَقَظَةِ، وَلاَ يَتَمَثَّلُ الشَّيْطَانُ بِي ". قَالَ أَبُو عَبْدِ اللَّهِ قَالَ ابْنُ سِيرِينَ إِذَا رَآهُ فِي صُورَتِهِ.
Whoever sees me in a dream will see me in his wakefulness, and Satan cannot imitate me in shape." Abu `Abdullah said, "Ibn Seereen said, 'Only if he sees the Prophet (ﷺ) in his (real) shape. - https://sunnah.com/bukhari/91/12
To understand this, we first need to understand how the science of hadith works or was intended to work. As known, a hadith is a saying that we except go back to the Prophet by a chain of narrations.
Imagine the prophet (saw) speaking to his companions, telling them "whoever sees me in a dream has seen me, because Satan cannot take my form." The sahaba, who knows how the Prophet looks, will now mention this hadith to other people (in the chain), they will then mention it further until a point, people no longer know how he looks.
If you do not know how the prophet looks, you cannot draw the conclusion saying I saw the Prophet. As you see in the above hadith; "Ibn Seereen said, 'Only if he sees the Prophet (ﷺ) in his (real) shape". How do you know this is the real shape of the Prophet, when you never actually have seen him? You might say, "well Satan cannot imitate and takes his shape", but even though this is true how do you know that Satan isn't imitating another shape, because you don't know his (pbuh) true shape?
Therefore, we who never have seen the Prophet, will never be able to differentiate and know if the person in the dream is the Prophet or not. The prophet never mentioned that we will see him. He was speaking to his companions who knew him.
With this understanding, its not possible to draw any conclusions from a dream, when one cannot be sure who one saw in the dream in the first place.
You will find different of opinions in this matter, for instance this, and this. But very few mentions the reality that you cannot differentiate and know for a fact who you have seen in your dream. You will also find minor opinions about dream interpretations only are for Prophets and ain't called dreams but rather visions.
There seems that some argue that we got some descriptions of how the Prophet looked in the ahadith, and by that they somehow could draw the conclusion that it was he who they saw in their dream. This argument is very very weak and bad, because the description we have cannot in any way give us a picture of how the Prophet really looked. The description could fit tens of thousands different shapes. See the description here: "How did the Prophet Muhammad look like?".
You can see him in dreams but you have to know how he looka by reading hadith and words of sahabas that described him sources, he is neither tall nor short, hes neither dark or light, etc, and shaytan might come to you in other form and tell you that he is Prophet.