I/O Error: Cannot run program “javac”: CreateProcess error=2

Ever got this error while building a BB JDE (BlackBerry Java Development Environment) Project?

Building C:\Program Files\Research In Motion\BlackBerry JDE 4.3.0\bin\rapc.exe -quiet import=”..\..\..\..\..\Program Files\Research In Motion\BlackBerry JDE 4.3.0\lib\net_rim_api.jar” codename= .rapc warnkey=0×52424200;0×52525400;0×52435200 C:\ \ .java
I/O Error: Cannot run program “javac”: CreateProcess error=2, The system cannot find the file specified
Error while building project

First check that you have JDK properly installed on your computer. Go to Control Panel -> Add/Remove Programs.

If all that’s sweet - check the Environment path to ensure JDK is included. Go to My Computer -> Properties -> Advanced -> Environment. Under System variable Edit Path - and check to see if you have C:\Program Files\Java\jdk\bin.

If that doesn’t exist you’ll need to manually set the paths into the ide.ini when the BB IDE runs. Go to C:\Program Files\Research In Motion\BlackBerry JDE 4.7.0\bin - edit the ide.bat and add the following lines at the beginning:

SET PATH=C:\Program Files\Java\jdk\bin;C:\Windows;C:\Windows\system;C:\Windows\system32
SET JAVA_HOME=C:\Program Files\Java\jdk

Save, and restart you’re IDE - and re-build your project. Hopefully it’ll start working :)

  • Share/Bookmark

Tags: , , ,

3 Responses to “I/O Error: Cannot run program “javac”: CreateProcess error=2”

  1. rahul says:

    thanks a lot it help to serve my purpose.

  2. Rehab says:

    Thanks it solved the problem but make another problem
    I/O Error: com\rim\samples\device\accelerometerdemo\AccelerometerDemo.tmp (Access is denied)
    do you have any solution?

  3. Joey says:

    @Rehab, I haven’t had this problem before. Seems like permissions off the top of my head. Are you able to post more details?

Leave a Reply