Sunday, September 28, 2014

Tomcat 7 not Started Automatically

Tomcat 7 not Started Automatically


1. Open C: Drive
2. Open Program Files
3. Open Apache tomcat 7.0 folder
4. Open Bin Folder
5. Open Tomcat 7 Properties-
6. Select Compatibility



7. Select Run this program as an administrator


8. Click on Ok


9.  Repeat Same Procedure with tomcat7w file in same folder


8. After this your tomcat will start up  automatically on your computer start-up




Saturday, September 27, 2014

First Program Explanation

First Program Explanation-


public static void main(String args[])



public-  This Function is accessible without the object of that class.

static-   Static function created a common function for all object of That class. Static Variable and
             function can be called by class name

void -  This function does not return any value

String args[] - This is used to take value from command line at time of run command


System.out.println- System is the Package in Java -
                                   out is sub-package for output on screen
                                    

println-  Println add Enter  after printing that line


print-   Print add no Enter after printing that line


Your First Program

1.  Open Command Prompt

2. Go to Your Folder help of

                            cd  your folder path

3. Make Your first Java File

Notepad HelloWord.java


4. In Your Notepad type Following Code



public class HelloWord
{
public static void main(String args[])
{
System.out.println("Hello, Your welcome in India");
                System.out.print("Hii, ");
                System.out.println(" Your welcome in India");
                System.out.println("Hello, "+" Your welcome in India");

}
}

5. After Saving file again open cmd

6. Type Following Command for Compile Program

javac HelloWord.java


7. Type Following Command for run Program

java HelloWord

8. You See Following Output


Set Java Path by GUI

Set Java Path by GUI

1. Open My Computer->C: Drive->Program Files->Java->JDK Version->bin

  Copy This folder Path




2. Open My Computer Properties

  •                      Right Click on My Computer
  •                      Select Properties



3. Open Advanced System Setting-

    


4. Open Environment Variables-



5. Select Path Variable-



6. Click on Edit



7. Append Current path by    ;  (semicolon) and copied path


   






Configure Java by Command Prompt

Configure Java


1. Open Command Prompt-


2. Open My Computer->C: Drive->Program Files->Java->JDK Version->bin

  Copy This folder Path


3. Open Command Prompt Again

Enter this Command


set path=%path%;Your Path

Example:-   set path=%path%;C:\Program Files (x86)\Java\jdk1.8.0_05\bin

4. Enter Following Command to check

Javac


4. If you See above detail, means Your Java Path Successfully configure

5. Congratulation.. Run your Programs





Installing Java

Installing Java-


  1.  Double Click on Setup File
  2. Click on Next




3. Again Click on Next


 
4. As you continue it, Is will Install JDK and JRE



Download JDK

How Download Java for Your Computer-

  1.  Downloading Java-
    1. Open Your Browser.
    2. Open following URL-   Download Java

    3. Click on JDK Download-