import java.awt.event.MouseAdapter; import - TopicsExpress



          

import java.awt.event.MouseAdapter; import java.awt.event.MouseEvent; import java.sql.Date; import java.sql.SQLException; import java.util.ArrayList; import java.util.List; import javax.swing.JOptionPane; import javax.swing.ListSelectionModel; import Connection.ClientConnection; import Logic.Car; import Logic.Clients; public class ClientFrame extends javax.swing.JFrame { /** * Creates new form Client */ int numberOf; public ClientFrame() { initComponents(); } List client; ClientConnection Ccon ; Clients cli; /** * This method is called from within the constructor to initialize the form. * WARNING: Do NOT modify this code. The content of this method is always * regenerated by the Form Editor. */ @SuppressWarnings("unchecked") // private void initComponents() { List c = new ArrayList(); try { Ccon= new ClientConnection(); client = Ccon.getList(); numberOf=client.get(client.size()-1).getCID(); } catch (SQLException e) { // TODO Auto-generated catch block e.printStackTrace(); } jPanel1 = new javax.swing.JPanel(); jLabel1 = new javax.swing.JLabel(); jPanel2 = new javax.swing.JPanel(); jButton1 = new javax.swing.JButton(); jButton2 = new javax.swing.JButton(); jButton3 = new javax.swing.JButton(); jButton4 = new javax.swing.JButton(); jScrollPane1 = new javax.swing.JScrollPane(); jTextArea1 = new javax.swing.JTextArea(); jButton5 = new javax.swing.JButton(); jButton6 = new javax.swing.JButton(); jTable1 = new javax.swing.JTable(); jScrollPane2 = new javax.swing.JScrollPane(); setDefaultCloseOperation(javax.swing.WindowConstants.EXIT_ON_CLOSE); jPanel1.setBackground(new java.awt.Color(124, 121, 121)); jPanel1.setBorder(javax.swing.BorderFactory.createBevelBorder(javax.swing.border.BevelBorder.RAISED)); jLabel1.setFont(new java.awt.Font("Narkisim", 0, 24)); // NOI18N jLabel1.setForeground(new java.awt.Color(0, 51, 153)); jLabel1.setText(" Client Table"); jPanel2.setBackground(new java.awt.Color(124, 121, 121)); jPanel2.setBorder(javax.swing.BorderFactory.createBevelBorder(javax.swing.border.BevelBorder.RAISED, new java.awt.Color(0, 51, 153), new java.awt.Color(0, 51, 153), new java.awt.Color(0, 51, 153), new java.awt.Color(0, 51, 153))); jButton1.setBackground(new java.awt.Color(0, 51, 153)); jButton1.setForeground(new java.awt.Color(204, 204, 204)); jButton1.setText("Insert"); jButton1.addActionListener(new java.awt.event.ActionListener() { public void actionPerformed(java.awt.event.ActionEvent evt) { jButton1ActionPerformed(evt); } }); jButton2.setBackground(new java.awt.Color(0, 51, 153)); jButton2.setForeground(new java.awt.Color(204, 204, 204)); jButton2.setText("Delete"); jButton2.addActionListener(new java.awt.event.ActionListener() { public void actionPerformed(java.awt.event.ActionEvent evt) { jButton2ActionPerformed(evt); } }); jButton3.setBackground(new java.awt.Color(0, 51, 153)); jButton3.setForeground(new java.awt.Color(204, 204, 204)); jButton3.setText("Update"); jButton3.addActionListener(new java.awt.event.ActionListener() { public void actionPerformed(java.awt.event.ActionEvent evt) { jButton3ActionPerformed(evt); } }); jButton4.setBackground(new java.awt.Color(0, 51, 153)); jButton4.setForeground(new java.awt.Color(204, 204, 204)); jButton4.setText("Search"); jButton4.addActionListener(new java.awt.event.ActionListener() { public void actionPerformed(java.awt.event.ActionEvent evt) { jButton4ActionPerformed(evt); } }); Object[][] obj = new Object[client.size()][11]; for (int i=0 ; i
Posted on: Sun, 01 Sep 2013 08:50:45 +0000

Trending Topics



Recently Viewed Topics




© 2015