When you recive the deployment error in netbeans that's mean you are missing these settings please do set these settings.




JDK Path Setting:

Follow the given steps below to set the PATH

  1. After installing jdk, right click “My Computer” icon
  2. Choose “Properties” from context menu
  3. Click “Advanced” tab and the click ‘Environment Variable
  4. In the Edit windows, modify PATH by adding the location of the class to the value for PATH. If you do not have the item PATH, you may select to add a new variable and add PATH as the name and the location of the class as the value. For example, if you have installed jdk in C drive then path may be in the form C:\Program Files\Java\jdk1.6.0_12\bin
  5. You will have to give your own path in which you have installed jdk.
  6. Open Command prompt window, and run your java code.


Compiling and running code
After installing jdk and path setting correctly, you can now compile and run your code on command prompt.
In order to compile the code, you have to use javac command. You can use this command as follow:
javac filename.java

After successfully compiling code, you can now run the code. You have to use java command to run the code. You can use the run command as follow:
java filename

Sponsored Links