Skip to main content

Using Eclipse: an Introduction

r-onlineinformation.blogspot.com 

Using Eclipse: an Introduction

STARTING ECLIPSE
  1. Start eclipse by directly Biologydouble clicking the file "eclipse" inside the extracted folder (Eg. /home//Desktop/software/eclipse. This could be different and depends on where you have extracted the eclipse archive).
  2. Select the working directory to save your current project. The default directory will be /home//workspace

Start A New Project
  1. Click File->New
  2. Choose "Dynamic Web Project"
  3. Provide a name for the project
  4. Choose the option "New Runtime" and a New runtime window opens
    1. Choose "Apache Tomcat v7.0" and say Next.
    2. In the "Tomcat installation directory", browse and select "/home//Desktop/software/apache-tomcat-7.0.2"
    3. Click Finish
  5. Click Finish
Running a Hello world program in eclipse

  1. Click File-> New -> Java project -> give project name -> finish
  2. Right click on project name -> new -> class
  3. Select "Class" and say Next.
  4. Give a class name, say "HelloWorld" and say Finish.
  5. Write a main method inside the class as follows:
    • public static void main(String[] args){
      System.out.println("Hello world");
      }
  6. Save the file(Ctrl+S) and Right-click anywhere in the editor window and select Run As > Run as Java Application
  7. It runs and prints Hello world in the Console window.
Including the JDBC - PostgreSQL driver in the project build path
  1. Make sure you have the postgresql JDBC jar file. It can be downloaded from here. After downloading, copy it (Right-click, select copy).
  2. For normal Java project(simple JDBC) follow these instructions:  right click on project name -> Build Path -> configure build path-> libraries (tab)  -> Add external Jars -> browse postgresql JDBC jar file-> OK
  3. For  Dynamic Web project (Servlets) follow these instructions: In Eclipse, open Project Explorer, select the current project and browse to WebContent > WEB-INF > lib, and paste(Right-click, select paste) the copied postgresql JDBC jar file  'lib' folder.
  4. Now, create a new class and copy the contents of the sample JDBC program from here.
  5. Start your postgresql server before running this program.
  6. Update the source code with the database name, username, password etc. as described in comments in the sample program.
  7. Run as Java application(Right-Click, select Run As > Java Application). The sample program takes in a department name and prints out all its student details. Enter a valid dept_name and hit enter. It should print the output successfully.
reference: iitb.ac.in/moodle
 

Comments

Popular posts from this blog

Create Custom ScreenTips for Shapes (MSOffice-word-2007)

r-onlineinformation.blogspot.com Create Custom ScreenTips for Shapes Shape ScreenTips in Microsoft Office Visio are the boxed text that appears when you point to a shape. Some Visio shapes have built-in ScreenTips—usually the name of the shape (such as the name of a workflow step). However, you can edit existing ScreenTip text or create new ScreenTip text for shapes that don’t have a built-in ScreenTip. To create or edit a ScreenTip: 1. Select the shape. 2. On the Insert menu, click either Shape ScreenTip or Edit Shape ScreenTip, as applicable. 3. In the Shape ScreenTip dialog box, type or edit the ScreenTip text. 4. Click OK.

For Searching CSS Template (Free)

r-onlineinformation.blogspot.com   For Searching CSS Template  http://www.freecsstemplates.org/ http://www.bestfreetemplates.info/ http://www.freecsstemplates.com/ http://www.free-css-templates.com/ http://www.freecsstemplates.in/ http://www.free-css.com/free-css-templates/page1.php http://www.csstemplatesfree.org/ http://csstemplatesmarket.com/ http://csstemplatesfree.net/ http://www.templatemo.com/page/1 http://www.csstemplatesforfree.com/csstemplates.aspx http://all-free-download.com/free-website-templates/ http://www.template4all.com/css/ http://www.csstemplatesforfree.org/ http://www.mediavolo.com/?d=1  you may also search free css template for educational purpose from any famous search engine..  

Some tips in creating a strong password

r-onlineinformation.blogspot.com * Avoid using any words that you can look up in a dictionary. These include common misspellings of words. * If you follow good security practices and try to change your password every say 6 months, do not just increment a digit or the digit in your current password * Avoid creating a password that begins or ends with a number because they can be easily guessed that passwords which have a number in the middle. * Avoid creating a password which someone can easily guess by knowing a little bit about you. This includes names of pets or family members or sports teams. * Avoid creating a password which includes words for popular culture. * Always create a password that requires the usage of both hands on the keyboard. Why is this important? So someone who may be looking over your shoulder don't need to worry about just looking on one side of the keyboard. Again much easier to guess. * Always have a password that uses uppercase and lowercase letters, has n...