Java Programming Archive

xPath Processing for XML documents using Java

As defined earlier, XPath is a language for finding and searching information in an XML document using Path Expressions which is similar to the file system syntax. [info]To practice more about xPath, you can visit this page[/info] 1 If you can using Eclipse or other IDE, you may create a new project. ...Read More

Database Porgramming : Creating a simple phone book using Java & a database ( HSQLDB )

[info] You to have Java and Eclipse Configured and Installed. If not please install the JDK and download Eclipse[/info] In one of the last tutorial, we have created a simple phonebook system using a text file and Java Programming. For more details, click here. In this tutorial, we will be creating the ...Read More

Java & HSQLDB : Connecting to a DBMS (HSQLDB) from Java Program

[info]In case you don’t have the HSGLDB, You can download the DBMS : HSQLDB from here [/info] 1) Create a simple file and call it Simple.java. Here is a simple code written in Java to connect to a DBMS : import java.io.*; import java.sql.*; import java.util.*; public class Simple { public static ...Read More

Java Programming : Creating a Phonebook using a simple CSV file

[info] You to have Java and Eclipse Configured and Installed. If not please install the JDK and download Eclipse[/info] In this tutorial, we will create a simple phonebook system using a text file. This is without accessing or using any advanced database management system like Access, MySQL or Oracle. The program will ...Read More

Installing & Configuring Java Development Kit ( JDK )

[info]This tutorial is for people using Windows[/info] 1. You need to download the Java Development Kit ( JDK ) from Oracle website.    http://www.oracle.com/technetwork/java/javase/downloads/index.html 2. Double click on the downloaded file [jdk-7-windows-i586.exe]   3. Click : Start -> right click on Computer -> click on Properties   4. Click on Advanced system settings ...Read More

Reading from a text file using Java

[info]You need to have JDK/Eclipse installed on your PC[/info] 1. Open your Eclipse and remember the location of your workspace 2. Create a new Project : MyReadFileProj  [ Click here for steps to create a new project ] 4. Right Click on MyReadFileProj : New -> File 4, Type the name of ...Read More

Java Simple Program to write text data to a file

[info]You need to have JDK/Eclipse installed on your PC[/info] 1. Open Eclipse and REMEMBER the workspace location 2. New project : MyWriteFileProj   [ Click here for steps to create a new project ] 3. New Class under the project : MyWriteFile 4. Type in the following code under your class : MyWriteFile ...Read More

Java Programming : Creating a simple java project using Eclipse

In this tutorial, we will learn how to read and write a simple text to a file. [info] You need to JDK ( Java Development Kit ) installed. JDK can be downloaded from here[/info] [info] You need also to download Eclipse and install it. You can download it from here[/info] 1. You ...Read More