10

I setup Nodeclipse and wrote a simple hello app. When I try to run as a Node Appplication, I get the following error

Exception occurred executing command line. Cannot run program "node" (in directory "C:\path\to\app"): CreateProcess error=2, The system cannot find the file specified

If I run from the Nodejs console, the app runs.

Is there a way I can make it runnable from Nodeclipse?

user3095242
  • 133
  • 1
  • 1
  • 8

7 Answers7

27

I know this question is a month old, but I was getting the same error and managed to fix it.

Try going to Window -> Preferences -> Nodeclipse and unchecking the box that says "find node on PATH...". Then make sure the "Node.js path" below is set to the location of the node.exe file (for me it was C:\Program Files (x86)\nodejs\node.exe).

I'm not sure why this worked (I checked my PATH and nodejs is definitely in there), but maybe it will help someone else.

Jordan
  • 310
  • 1
  • 3
  • 8
5

this error is show cause your node.exe is not configured in PATH simple solution is configure it or use below method go to windows -> preferences -> nodeclipse and uncheck the checkbox (find node on PATH) it works

Sumeet_Pol
  • 929
  • 8
  • 13
1

Do you have Node.js installed? What is path to it?

Check Window -> Preferences -> Nodeclipse and compare.

http://www.nodeclipse.org/#support have also other option to follow with

Quote:

  • How do I? -- 1) F1/Help -> Help Contens -> Nodeclipse Help , 2) Online Help or 3) StackOverflow! *1
    *1 Don't forget to add `nodeclipse` tag.
  • I got this error, why? -- StackOverflow! *1
  • I got this error and I'm sure it's a bug -- raise an issue!

Should you report a bug, please include the following:

  1. Nodeclipse version number (like 0.4 or 0.8)
  2. Eclipse version number (like 4.3.1 Kepler or 4.4.0)
  3. Eclipse distribution (e.g. Eclipse for Java EE Developers)
  4. A detailed description of the steps necessary to reproduce the problem.
  5. Screenshot and stack trace, that you can get from Eclipse Error Log View (Window -> Show View ...) or from '.log' file from the directory '.metadata' in your workspace.
  6. See example issue #78
Community
  • 1
  • 1
Paul Verest
  • 60,022
  • 51
  • 208
  • 332
  • The path in preferences matches the current installation path. I have even gone as far as playing around with other preference settings but it still doesn't work. I will see of I can report the bug to support. – user3095242 May 30 '14 at 12:07
0

After you install node.js plugin in eclipse, then go to https://nodejs.org/en/ official website, and install v4.2.6 LTS open source libraries, after double click install, then restart eclipse, then done!

Kyle
  • 81
  • 1
  • 3
0

in system Path variable -nodejs would be mentioned as C:\Program Files\nodejs\ whereas we need to include node.exe i.e C:\Program Files\nodejs\node.exe So either we can

  1. uncheck the checkbox "find node on PATH.Otherwise use Node.js instance in location below.

or

  1. add the node.exe in system path variable.

enter image description hereAdded IDE image (1 option) so that its easily to fix.

Benkerroum Mohamed
  • 1,867
  • 3
  • 13
  • 19
V.Arvind
  • 1
  • 2
0

Same here, I restarted Eclipse and it worked ok.

Eclipse loads variable PATH when started - in my case I installed Nodejs when executing Eclipse.

patricK
  • 1,045
  • 11
  • 27
0

In addition to Jordan's answer above (configure Node.js path) I also needed to configure the Javascript runtime library with a Node.js runtime before being able to "Run As" a "Node.js Application" and point to the node.exe path. The same path as the separate Node.js path Jordan mentioned.

Preferences > JavaScript > Runtimes > [select Node.js Runtime] > Add : path to node.exe