Logo Questions Linux Laravel Mysql Ubuntu Git Menu
 

Run button is greyed out - intellij

I was working on a project in Intellij then suddenly there was a pop up and now the run button is greyed out. It is a Java FX project and it runs with coverage and debug, but the normal run button is greyed out. What could be the problem?

PS: I know I don't give you much to work with but unfortunately it was working and now it isn't, that's all.

like image 649
arty Avatar asked Apr 04 '20 20:04

arty


People also ask

Why is IntelliJ Run button greyed out?

One possible problem is that the program is still running in the background and hasn't exited completely. Check your running processes for java applications and see if it exists. Or a variation - close Intellij window and reopen.

Why Run button is not working in IntelliJ IDEA?

Right click on main toolbar (where the button disappeared) > Customize Menus and Toolbars... > select Run/Debug > Restore Run/Debug. This didn't work for me however it helped me get to a solution that did work for me.

How do I enable run in IntelliJ?

From the main menu, select Run | Edit Configurations. Alternatively, press Alt+Shift+F10 , then 0 . on the toolbar or press Alt+Insert . The list shows the run/debug configuration templates.


3 Answers

I had the same issue and fixed it with the old "Invalidate Caches and Restart"

like image 92
Crompy Avatar answered Sep 20 '22 11:09

Crompy


Open the source code, right-click and hit run using the option run "filename.java".

IntelliJ will make the configuration for you and then you can click the run button after the configuration is made by the IDE.

Same thing for debug configuration.

like image 37
Doc Avatar answered Sep 20 '22 11:09

Doc


This has happened to me countless times. One possible problem is that the program is still running in the background and hasn't exited completely. Check your running processes for java applications and see if it exists.

like image 30
Jason Avatar answered Sep 20 '22 11:09

Jason