傻大方


首页 > 知识库 > >

学生|学生学籍管理系统有java源代码( 四 )


按关键词阅读: 学籍 学生 源代码 java 系统 管理


static JLabel label7 = new JLabel(系别 :);
static JTextField textField9 = 。

39、 new JTextField();
static JLabel label8 = new JLabel( 专业 :);
static JTextField textField5 = new JTextField();
static JButton button2=new JButton(修改 );
public xg()this.setTitle( 修改学生信息 );
this.setLayout(null);
this.setSize(400,400);
label1.setBounds(30, 11, 51, 33);
textField1.setBounds(86, 16, 74, 22) 。

40、;
label2.setBounds(162, 11, 51, 33);
textField2.setBounds(192, 16, 44, 22);
label3.setBounds(241, 11, 70, 33);
textField7.setBounds(275, 15, 50, 25);
label4.setBounds(31, 53, 55, 33);
textField3.setBounds(86, 58, 74, 22);
label5.setBounds(241, 53, 70, 33);
textField8.setBounds(296, 57, 72, 25);
labe 。

41、l6.setBounds(163, 53, 26, 33);
textField4.setBounds(191, 58, 44, 22);
label7.setBounds(30, 94, 50, 33);
textField9.setBounds(86,94,74,22);
label8.setBounds(163, 94, 51, 33);
textField5.setBounds(190, 99, 178, 22);
button2.setBounds(115,241,80,33);
button2.addActionListener(this);
this.add(label1);
thi 。

42、s.add(label2);
this.add(label3);
this.add(label4);
this.add(label5);
this.add(label6);
this.add(label7);
this.add(label8);
this.add(textField1);
this.add(textField2);
this.add(textField3);
this.add(textField4);
this.add(textField5);
this.add(textField7);
this.add(textField8);
this.add(textField9);
t 。

43、his.add(button2);
this.setDefaultCloseOperation(JFrame.DISPOSE_ON_CLOSE);
this.setVisible(true);
public static void main(String args) throws Exception xg a=new xg();
事件处理程序a.setDefaultCloseOperation(JFrame.EXIT_ON_CLOSE);
public void actionPerformed(ActionEvent e)/ if(e.getSource()=button2) tryClass.f 。

44、orName(sun.jdbc.odbc.JdbcOdbcDriver);
catch (ClassNotFoundException ce) JOptionPane.showMessageDialog(s,ce.getMessage();
tryxinxi where 学 号学号不可为空!Connection con = DriverManager.getConnection (jdbc:odbc:stu,sa,);
Statement stmt = con.createStatement();
ResultSet rs=stmt.executeQuery(select * from =+textF 。

45、ield1.getText()+);
if(textField1.getText().trim().equals()JOptionPane.showMessageDialog(this,);
else if(rs.next()String=+textField1.getText()+,=+updateSql=update姓名xinxiset 学 号=+textField7.getText()+,生日期 =+性别textField2.getText()+,出textField3.getText()+,政治面貌=+textField8.getText()系别+, 籍贯 =+textField4.get 。

46、Text()+,=+textField9.getText()+,业=+专textField5.getText()+ ;
trystmt.executeQuery(updateSql);
catch(SQLException se) JOptionPane.showMessageDialog(null, 修改成 功);
catch(SQLException se)JOptionPane.showMessageDialog(s,se.getMessage();
/sc.java 删除界面 import javax.swing.*;
import java.awt.*;
import java.aw 。

47、t.event.*;
import java.sql.*;
public class sc extends JFrame implements ActionListener static sc s;
static JLabel label1 = new JLabel(学号 :);
static JTextField textField1 = new JTextField();
static JLabel label2 = new JLabel(姓名 :);
static JTextField textField2 = new JTextField();
static JLabel label3 = n 。

48、ew JLabel(性别 :);
static JTextField textField7=new JTextField();
static JLabel label4 = new JLabel(出生日期 :);
static JTextField textField3 = new JTextField();
static JLabel label5 = new JLabel(政治面貌 :);
static JTextField textField8=new JTextField();
static JLabel label6 = new JLabel( 籍贯 );
static JTextField。

49、textField4 = new JTextField();
static JLabel label7 = new JLabel(系别 :);
static JTextField textField9 = new JTextField();
static JLabel label8 = new JLabel( 专业 :);
static JTextField textField5 = new JTextField();
static JButton button4=new JButton(删除 );
public sc() throws Exceptionthis.setTitle( 删除学生信息 。

50、 );
this.setLayout(null);
this.setSize(400,400);
label1.setBounds(30, 11, 51, 33);
textField1.setBounds(86, 16, 74, 22);
label2.setBounds(162, 11, 51, 33);
textField2.setBounds(192, 16, 44, 22);
label3.setBounds(241, 11, 70, 33);
textField7.setBounds(275, 15, 50, 25);
label4.setBounds(31, 53, 55, 33 。

51、);
textField3.setBounds(86, 58, 74, 22);
label5.setBounds(241, 53, 70, 33);
textField8.setBounds(296, 57, 72, 25);
label6.setBounds(163, 53, 26, 33);
textField4.setBounds(191, 58, 44, 22);
label7.setBounds(30, 94, 50, 33);
textField9.setBounds(86,94,74,22);
label8.setBounds(163, 94, 51, 33);
textField 。

52、5.setBounds(190, 99, 178, 22);
button4.setBounds(295,241,80,33);
button4.addActionListener(this);


来源:(未知)

【学习资料】网址:/a/2021/0322/0021748076.html

标题:学生|学生学籍管理系统有java源代码( 四 )


上一篇:婚礼|婚礼上的对联

下一篇:姜丝|姜丝洋葱拌皮蛋