We are back with a exciting game called minesweeper this game needs no introduction as it is the most oldest game.The only reason for sharing this game with you to provide a basic solutions of gaming in java-fx.So enjoy a free download of this game and feel free to share your opinion.
Showing posts with label Java Projects. Show all posts
Showing posts with label Java Projects. Show all posts
Saturday, 9 January 2016
Friday, 1 January 2016
java Fx, Java Projects
Tic Tac Toe Game In Java-Fx For Download
Tic tac toe is one of the most basic games in world of gaming.The reason of sharing this game code is to provide a opportunity to new game developers to learn basics of gaming in java-fx.This game is to free to download so grab it and don't forget share your reviews about it.
SNAP SHOT:
Saturday, 31 October 2015
Java Projects
Anagram Word Puzzle Game In Java
Today we are going to share with you an exciting word puzzle game in java this game generates an random scramble word user have to guess correct word if user guess correct word hi/her score will be increased.In this game user have also an option to skip the word.That is the complete description of a project.Download and enjoy this project don't forget to share your reviews.
SNAPSHOT:
DOWNLOAD THIS PROJECT:
Thursday, 22 October 2015
Java Projects, JDBC, Jswing
Employee Management Project In Java
This project completely based on jdbc and jswing.This is a perfect project for beginners who want to learn database management system in java.Following are the features of this project.
It can calculate salary of employee.
It can search employee record.
It can delete employee record.
FEATURES:
Save employee record.It can calculate salary of employee.
It can search employee record.
It can delete employee record.
OUTPUT:
DOWNLOAD THIS PROJECT:
DOWNLOAD
Saturday, 17 October 2015
Java Projects, JDBC, Jswing
How To Create A Login Frame With Create New Id Option In Java
In this tutorial we are going to create a login frame using jdbc in this login user can create a new his/her id with password.Let's start first create a new project in netbeans then create new jframe form.
Our project is successfully created must share your feedback about this project.
FINAL RESULT:
CREATING JPANEL:
Change layout of frame by pressing right click on frame then select layout>>Flowlayout.After this pick and drop jpanel in frame from palette.Change the colour of jpanel to make it attractive.
DESIGNING MAIN WINDOW:
Our next step is to create main window for our project for this following controls.
- Pick two label and drop in frame and edit text of label as shown in pictures.
- Select jtextfield and change it variable name to userfield.
- Create jpasswordfield and change its vraible name to passfield.
- Then create a button and change it's variable name and text to login.
- Finally create a button for a register a new user option change it's variable name as register.
After creating controls design your frame as shown in below picture by changing font style and colour of label and jbutton text change layout of your frame to make it attractive.
DESIGNING DIALOG BOX :
As a user click on click new id option new dialog box should be open so we have to create a dialog box for our login frame to create dialog box press right click on other component in navigator as shown in picture.
After this step you will see that dialog box will appear above frame in navigator change its variable name to box press double click on it to design now pick following components from palette:
- Three labels and change its text.
- One jtextfield and change it's variable as newid.
- Now Create jpasswordfield and change it's variable name as newpass
- Create jbutton and change its variable and text as create.
Our dialog box is completed set layout and design of dialog box as shown in below picture.
To make it accessible with our main frame double click on register button and paste a below code.
box.setVisible(true);
CREATE DATA BASE FOR LOGIN FRAME:
For this project we need a database for this frame I have created database in ms access.your next step is to create a table in ms access your table name should be logtab. Then create a data source your data source name should be login.Your table should contain two columns as shown in below picture.
CREATING METHOD FOR CREATE OPTION:
In this step we will code for create a new id option you have to simply paste a below code below constructor in code area
public void create(String a,String b)
{
try{
Statement st;
Class.forName("sun.jdbc.odbc.JdbcOdbcDriver");
Connection cn=DriverManager.getConnection("jdbc:odbc:login");
st=cn.createStatement();
st.executeUpdate("INSERT into logtab VALUES('"+a+"','"+b+"')");
JOptionPane.showMessageDialog (null,"New ID is Succesfully Created", "Message", JOptionPane.INFORMATION_MESSAGE);
box.dispose();
}
catch(Exception e)
{
JOptionPane.showMessageDialog (null, e, "Error", JOptionPane.ERROR_MESSAGE);
}
}
public void create(String a,String b)
{
try{
Statement st;
Class.forName("sun.jdbc.odbc.JdbcOdbcDriver");
Connection cn=DriverManager.getConnection("jdbc:odbc:login");
st=cn.createStatement();
st.executeUpdate("INSERT into logtab VALUES('"+a+"','"+b+"')");
JOptionPane.showMessageDialog (null,"New ID is Succesfully Created", "Message", JOptionPane.INFORMATION_MESSAGE);
box.dispose();
}
catch(Exception e)
{
JOptionPane.showMessageDialog (null, e, "Error", JOptionPane.ERROR_MESSAGE);
}
}
When a user clicks on create button above method should be called so double click on create button then copy below code in action performed method of create button.
String nid=newid.getText();
String pass=newpass.getText();
create(nid,pass);
CREATING METHOD FOR LOGIN OPTION:
In last create method for login option when user clicks on login below method should be call so paste below code after first method
public void match(String a,String b)
{
Boolean c = false,d=false;
try {
Connection cn=DriverManager.getConnection("jdbc:odbc:login");
Statement st=cn.createStatement();
ResultSet data,data1;
data=st.executeQuery("select * from logtab where id='"+a+"'");
if(data.next())
{
c = true;
}
else{
System.out.print("ID Not Matched ");
}
data1=st.executeQuery("select * from logtab where password='"+b+"'");
if(data1.next())
{
d = true;
}
else
{
System.out.println("password not match");
}
if(c & d)
{
System.out.print("Successfully Login ");
}
}
catch(Exception e)
{
System.out.print(e);
}
}
after copying this code paste below code in login action performed method code
String nid=newid.getText();
String pass=newpass.getText();
create(nid,pass);
Our project is successfully created must share your feedback about this project.
Sunday, 11 October 2015
Java Projects, Jswing
NotePad Project In Java
This project work same like notepad this is a great application to learn how simple text editor works it's coding is simple and easy to understand for beginners.following are the features of this project.
FEATURES:
This application can save file.
This application can open any txt format file.
It has copy,cut and paste options.
This application can open any txt format file.
It has copy,cut and paste options.
OUTPUT:
DOWNLOAD THIS PROJECT:
Subscribe to:
Posts (Atom)















