Solution:
Your difficulty is in this line: Message messageObject = new Message ();
This error indicates that the Message
class is not familiar at compile time.
So you require to import the Message class.
Something like this:
import package1.package2.Message;
I had a pair of various Java versions installed on my system. Hence foremost I uninstalled them all. Then I reinstalled the one i wanted to employ (which in my case is 8.0_151).
Then:
Go to Preferences >> Java >> Installed JRE's
Click on add and browse to \Program Files\Java\jdk1.8.0_151
In my example the "Location" variable for the jre did not alter however the "Name" variable for the jre in this dialog box did. I am not certain the influence of this however it is the only matter that seems to have altered. Who knows, maybe "refreshing" this variable is the key.Click OK and then place the newly included jre as the default.
Click OK, tell a small prayer and run a job.
Hopefully, You are able to solve this problem.