My application isn't running correctly with Java 9. In order to debug it, I upgraded to Eclipse 4.7 (oxygen) since Neon doesn't have Java 9 support, and applied the Java 9 support patch.
After doing so, eclipse was failing to load any of my pre-existing Java Applications. Thinking it might be a version difference thing, I deleted them, to try re-adding. But when I click the "New" button to add a configuration, nothing happens.
If I double-click "Java Application," I get the following error:
An error has occurred. See error log for more details.
tried to access method org.eclipse.debug.internal.ui.launchConfigurations.LaunchConfigurationsDialog.getTabViewer()Lorg/eclipse/debug/internal/ui/launchConfigurations/LaunchConfigurationTabGroupViewer; from class org.eclipse.jdt.internal.debug.ui.launcher.LocalJavaApplicationTabGroup
I am able to add configurations for other types of applications (Java Applet, Eclipse Application) so it seems only to be an issue with Java Applications.
I also tried a fresh workspace, but that has the same issue. How can I fix this?
Run As > Java Application wont show up if the class that you want to run does not contain the main method. Make sure that the class you trying to run has main defined in it. It did have. It is just that it didn't show the run as app.
right click on you project in project explorer,then choose run configuratin,in the "type filter text" text box type "java application" ,select it and choose prespective link on the right side. select Java Application in "Application Type/Launchers:" list box. Then select "Java" in "Run" drop down box. apply>ok.
In Eclipse look at Project -> Properties for the project you want a runtime configuration. Choose Run/Debug settings and choose new or edit one you already have. When creating a New run/debug config make sure to choose Java Project. When the dialog box opens you will see a tab for classpath directives.
I am doing a Java project in Eclipse on Windows. I implemented some methods and tried to test them. But, in Eclipse run or run as seem to be empty. When I try to right click to my project on package explorer and choose run as Java Application, a pop-up shows up and says Select Java Application.
when you created your project, have u selected file>new>Java Project. right click on you project in project explorer,then choose run configuratin,in the "type filter text" text box type "java application" ,select it and choose prespective link on the right side. select Java Application in "Application Type/Launchers:" list box.
To create a run configuration for a Java application select Java Application from the list on the left hand side and click on the New button. A name for the run configuration. The name of a Project. The name of the main class. Zero or more program arguments. Zero or more Virtual Machine arguments.
Eclipse - Run Configuration. Creating and Using a Run Configuration. The Run Configurations dialog allows you create multiple run configurations. Each run configuration can start an application.
This is kind of a duplicate but since I experienced the issue and have seen a few others post about it, I'll post my answer of how I fixed it here.
If you go here: https://marketplace.eclipse.org/content/java-9-support-beta-oxygen/
You need to follow the step about updating Eclipse 4.7 from the link that ends in 4.7-U-builds. When you go to Install New Software and select Eclipse SDK, click Next until you get to the Install Remediation Page, and make sure that you are selecting the second option that says something like "update my installation to be compatible with the items being installed" instead of the option that says "keep my installation the same and modify the items being installed to be compatible."
The first time I installed Java 9 updates, I did it the latter way and ran into this problem. Now that I've gone back and chosen the former, I am able to add Java Application Run Configurations again.
Hope this helps.
If you love us? You can donate to us via Paypal or buy me a coffee so we can maintain and grow! Thank you!
Donate Us With