How to set path and classpath variable for java in Windows 7

Hello Friends i am writing this post to help people like me who have started learning selenium and since in selenium RC and WebDriver we use java so need to set classpath and path comes in to our way becuase we use Eclipse IDE for selenium automation script. So hope this post will help us all and if i am leaving anything then please write your view here as your comment

1-      Download  JDK 6 or 7

2-      Install JDK  and by Default Java installs at at this place  C:\Program Files\Java

3-      Java folder contain two folder of name jdk1.6.0_20 and jre6

4-      Now we will set the classpath and path for java in our windows 7 machine

5-      Right Click on My Computer

6-      Now click on Advanced System Setting.

                       

7-      Click on Environment Variables on next window that appears after clicking Advanced System Setting.

 

8-      Click on New  under system variable on Environment Variables Window

 

9-      A new window for New System Variable will open

10-   Before Variable Name  write path

11-   Before variable value type C:\Program Files\Java\jdk1.6.0_20\bin

12-   Click on Ok

13-   Now to set classpath again click on New and again New System Variables  will appear

14-   Enter

Variable name = classpath and Variable Value = C:\Program Files\Java\jdk1.6.0_20\lib

 

15-   Now click Ok  and again click Ok on Environment Variables

16-   Finally we have set path and classpath  and now start you java coding  best of luck

 

 

About these ads

One thought on “How to set path and classpath variable for java in Windows 7

  1. Pingback: Java Tutorial 1 – Installation vom JDK und eclipse [GERMAN] | Floodle

Leave a Reply

Fill in your details below or click an icon to log in:

WordPress.com Logo

You are commenting using your WordPress.com account. Log Out / Change )

Twitter picture

You are commenting using your Twitter account. Log Out / Change )

Facebook photo

You are commenting using your Facebook account. Log Out / Change )

Connecting to %s