Sindhu - For Merge
Sindhu - For Merge
Certified that this project report titled TGWS BOARD RESULTS is the bonafide work of
SINDHU, who carried out the research under my supervision. Certified further, that to the best of my
knowledge the work reported herein does not form part of any other project report.
Ranipet. Ranipet.
Place : Ranipet
Date :
1
ACKNOWLEDGEMENT
I first offer my thanks to the almighty who has given me the strength and good health during the course
of this project.
I am also thankful to Miss. G.Vaishnavi, IT Facilitator, for her continual support and assistance.
I also thank all my faculty members who were instrumental in the completion of this project.
SINDHU
2
Table Of Contents
1 Introduction 5
2 Project Description 6
4 Program 7
5 Snapshots 16
6 Tables Used 19
8 Conclusion 21
Reference 22
List Of Figures
3
Fig No Title Page No
5.1 app1.java 16
5.2 app2.java 16
5.3 app3.java 17
5.4 app4.java 17
5.5 app5.java 18
5.6 app6.java 18
1. INTRODUCTION
The project titled TGWS Board Results is system for viewing results of the students. This
project is designed and coded in NetBeans 8.0.2 and database management is handled by
MySQL 5.0. This software mainly focuses on the following,
I. Uploading results of the students by the teachers
II. Viewing the result by the students.
4
2. PROJECT DESCRIPTION
The goal of this project is to make the works of the teachers easier by uploading students marks
in the database so that those data will be retrieved when the students are in need of.
5
4. PROGRAM
4.1 app1.java
jButton1(Teachers Login):
obj.show();
jButton2(Students Login):
obj.show();
4.2 app2.java
jButton1(Login):
String pwd;
pwd=jPasswordField1.getText();
if(pwd.equals("TGWS"))
6
app3 obj=new app3();
obj.show();
else
4.3 app3.java
import java.sql.DriverManager;
import java.sql.Connection;
import java.sql.ResultSet;
import java.sql.Statement;
import javax.swing.JOptionPane;
import javax.swing.table.DefaultTableModel;
jTextField2.setEnabled(true);
jTextField3.setEnabled(true);
jTextField4.setEnabled(true);
jTextField5.setEnabled(true);
jTextField6.setEnabled(true);
jTextField7.setEnabled(true);
jTextField8.setEnabled(true);
7
jTextField9.setEnabled(true);
String rno=jTextField1.getText();
jTextField2.setEditable(false);
jTextField3.setEditable(false);
jTextField4.setEditable(false);
jTextField5.setEditable(false);
jTextField6.setEditable(false);
jTextField7.setEditable(false);
jTextField8.setEditable(false);
jTextField9.setEditable(false);
if(rno.isEmpty())
try
Class.forName("java.sql.DriverManager");
Connection con=
(Connection)DriverManager.getConnection("jdbc:mysql://localhost:3306/project","root","school");
Statement stmt=(Statement)con.createStatement();
ResultSet rs=stmt.executeQuery(query);
if(rs.next())
String Name=rs.getString("Name");
String english_core=rs.getString("english_core");
8
String physics=rs.getString("physics");
String chemistry=rs.getString("chemistry");
String biology=rs.getString("biology");
String informatics_partices=rs.getString("informatics_partices");
String total=rs.getString("total");
String avgerage=rs.getString("avgerage");
jTextField2.setText(Name);
jTextField3.setText(english_core);
jTextField4.setText(physics);
jTextField5.setText(chemistry);
jTextField6.setText(biology);
jTextField7.setText(informatics_partices);
jTextField8.setText(total);
jTextField9.setText(avgerage);
else
catch (Exception e)
JOptionPane.showMessageDialog(this, e.getMessage());
4.4 app4.java
jButton(Login):
9
String pwd;
pwd=jPasswordField1.getText();
if(pwd.equals("TGWS123"))
obj.show();
else
4.5 app5.java
jButton1(Upload Data):
import java.sql.DriverManager;
import java.sql.Connection;
import java.sql.ResultSet;
import java.sql.Statement;
import javax.swing.JOptionPane;
import javax.swing.table.DefaultTableModel;
String rno=jTextField1.getText();
String name=jTextField2.getText();
String english_core=jTextField3.getText();
10
String physics=jTextField4.getText();
String chemistry=jTextField5.getText();
String biology=jTextField6.getText();
String informatics_partices=jTextField7.getText();
String total=jTextField8.getText();
String avgerage=jTextField9.getText();
try
Class.forName("java.sql.DriverManager");
Connection
con=(Connection)DriverManager.getConnection("jdbc:mysql://localhost:3306/project","root","school");
Statement stmt=(Statement)con.createStatement();
stmt.executeUpdate(query);
catch (Exception e)
JOptionPane.showMessageDialog(this, e.getMessage());
jButton2(Clear):
jTextField1.setText("");
11
jTextField2.setText("");
jTextField3.setText("");
jTextField4.setText("");
jTextField4.setText("");
jTextField5.setText("");
jTextField6.setText("");
jTextField7.setText("");
jTextField8.setText("");
jTextField9.setText("");
jButton3(View):
obj.show();
jButton4(calculate):
float eng,phy,chem,bio,ip,total,avg;
eng=Float.parseFloat(jTextField3.getText());
phy=Float.parseFloat(jTextField4.getText());
chem=Float.parseFloat(jTextField5.getText());
bio=Float.parseFloat(jTextField6.getText());
ip=Float.parseFloat(jTextField7.getText());
total=eng+phy+chem+bio+ip;
avg=(eng+phy+chem+bio+ip)/5;
12
jTextField8.setText(String.valueOf(total));
jTextField9.setText(String.valueOf(avg));
4.6 app6.java
jButton1(Click To View):
DefaultTableModel model=(DefaultTableModel)
jTable1.getModel();
try
Class.forName("java.sql.DriverManager");
Connection
con=(Connection)DriverManager.getConnection("jdbc:mysql://localhost:3306/project","root","school");
Statement stmt=(Statement)con.createStatement();
String tname;
tname="result";
ResultSet rs=stmt.executeQuery(query);
while(rs.next())
String rno=rs.getString("rno");
String name=rs.getString("name");
String english=rs.getString("english_core");
String physics=rs.getString("physics");
String chemistry=rs.getString("chemistry");
String biology=rs.getString("biology");
13
String ip=rs.getString("informatics_Partices");
String total=rs.getString("total");
String avg=rs.getString("avgerage");
model.addRow(new Object[]{rno,name,english,physics,chemistry,biology,ip,total,avg});
catch(Exception e)
JOptionPane.showMessageDialog(this,e.getMessage());
5. SNAPSHOTS
5.1 app1.java
14
5.2 app2.java
5.3 app3.java
15
5.4 app4.java
5.5 app5.java
16
5.6 app6.java
6. TABLES USED
6.1 Table 1: result
17
7. VIEWING TABLE DATA
18
8. CONCLUSION
19
REFERENCES:
1) https://www.google.co.in/search?
q=tn+board+results&source=lnms&tbm=isch&sa=X&ved=0ahUKEwiSs6Py_LHQAhW
Lp48KHRwCBIYQ_AUICSgC
2) Informatics Practices Text Book (Grade 12)
20