Error: Could not find or load main class Unit2.ReadNames2
Caused by: java.lang.ClassNotFoundException: Unit2.ReadNames2
The above error is produced every single time I try to run any of my (newer or recently edited) class in any of my Java projects on my Eclispe IDE. But what confuses me even more is that if I try to run any of my older (already coded and not recently edited or changed) classes, they work perfectly fine, but as soon as I edit it or even do so much as add a couple characters and then save, compile and run it, I gives the error again?! I am lost and have tried turning to Google’s numerous websites, articles and sources and came up with nothing of use or that actually works.. If anyone knows what to do and how I can fix this, please let me know..
I have tried turning to Google for answers and solutions. I have tried re-configuring and rebuilding my projects as well as their build-paths (Class Paths, Module Paths and Project Paths included). I have tried uninstalling and reinstalling my JAR files. I have checked and validated (to the best of my knowledge) any and all possible JAR (and other) files that could be causing the problems. I have tried cleaning all my projects (Using the “Project>Clean” option). And it still persists.
Richard West is a new contributor to this site. Take care in asking for clarification, commenting, and answering.
Check out our Code of Conduct.