java学生管理系统oracle_基于java和oracle的学生信息管理系统

41528d3028836879cd698677c3999917.gif基于java和oracle的学生信息管理系统

1学生信息管理系统自己做的学生信息管理系统,由于能力有限,其中的错误和不足较多,但可以正常运行也加入了必要的提示操作,希望能为有需要的童鞋一些启示。附录:学生信息管理系统代码1.登录界面1.1登录界面模块//函数库import java.awt.*;import javax.swing.*;import java.awt.event.*;import java.sql.*;//登录界面主程序public class system extends JFrame implements ActionListener{private static final long serialVersionUID = 1L;static system ss;JPanel panel = new JPanel();JMenuBar jmb1 = new JMenuBar();JMenuBar mBar=new JMenuBar();JMenu Help = new JMenu(“ 帮 助 “);JMenu About = new JMenu(“ 关 于 “); JMenuItem Password = new JMenuItem(“忘 记 密 码“);JMenuItem Aboutus = new JMenuItem(“关 于 软 件“);//设置姓名、密码、登陆、退出按钮JLabel label1 = new JLabel(“账 号“);JTextField usernumber = new JTextField();JLabel label2 = new JLabel(“密 码“);JPasswordField pwd = new JPasswordField();JButton Enter = new JButton(“登 录“);JButton Exit = new JButton(“退 出“);//设置主题图片String url = “C:\\Users\\Design\\Capture.PNG“;ButtonGroup bgp = new ButtonGroup();//设置学生、教师角色,并设置角色按钮2JRadioButton stu = new JRadioButton(“学 生“);JRadioButton tch = new JRadioButton(“教 师“);public system(){//设置窗口题头super(“***学生管理系统“);this.setSize(500,400);this.setResizable(false);panel.setOpaque(false); this.setJMenuBar(jmb1);JLabel img = new JLabel(new ImageIcon(url));img.setBounds(0,0,575,70);Password.addActionListener(this);Aboutus.addActionListener(this);setJMenuBar(jmb1);//向面板中一次添加图片、按钮,并设置按钮尺寸jmb1.add(Help);jmb1.add(About);Help.add(Password);About.add(Aboutus);mBar.add(Help);mBar.add(About);setJMenuBar(mBar);panel.add(img);stu.setBounds(210,150,70,30);tch.setBounds(310,150,70,30);bgp.add(stu);bgp.add(tch);panel.add(stu);panel.add(tch);Enter.setBounds(210,180,70,20);Exit.setBounds(290,180,70,20);Enter.addActionListener(this);Exit.addActionListener(this);3Help.setForeground(Color.blue);Password.setForeground(Color.blue);About.setForeground(Color.blue);Aboutus.setForeground(Color.blue);panel.add(Enter);panel.add(Exit);panel.setLayout(null);this.add(panel);label1.setBounds(175,90,50,25);panel.add(label1);usernumber.setBounds(210,90,150,25);panel.add(usernumber);label2.setBounds(175,125,50,25);panel.add(label2);pwd.setBounds(210,125,150,25);panel.add(pwd);this.setBounds(110,60,540,320);//将当前窗口防止在屏幕中央setLocationRelativeTo(null);//setVisible(true);this.setVisible(true);this.setDefaultCloseOperation(JFrame.EXIT_ON_CLOSE);}@SuppressWarnings(“deprecation“)public void actionPered(ActionEvent e){String id , password;id= usernumber.getText();password = pwd.getText();if(e.getSource()==Password)JOptionPane.showMessageDialog(this,“请联系任课教师重置密码 !“,“忘记密码“,JOptionPane.INATION_MESSAGE);if(e.getSource()==Aboutus)JOptionPane.showMessageDialog(this,“作 者: 张三\n\n 单 位: 4信 息 工 程 学 院\n\n 版 本: Version 1.1.8“,“关于软件“,JOptionPane.INATION_MESSAGE);if(e.getSource()==Exit){System.exit(0);}if(e.getSource()==Enter){//加载数据库驱动try{Class.forName(“oracle.jdbc.driver.OracleDriver“);}catch (ClassNotFoundException ce){JOptionPane.showMessageDialog(ss,ce.getMessage());} if(!(stu.isSelected())}else if(stu.isSelected()){if(id.equals(““)||password.equals(““))//如果没输账号或密码,则提

  • 0
    点赞
  • 1
    收藏
    觉得还不错? 一键收藏
  • 0
    评论

“相关推荐”对你有帮助么?

  • 非常没帮助
  • 没帮助
  • 一般
  • 有帮助
  • 非常有帮助
提交
评论
添加红包

请填写红包祝福语或标题

红包个数最小为10个

红包金额最低5元

当前余额3.43前往充值 >
需支付:10.00
成就一亿技术人!
领取后你会自动成为博主和红包主的粉丝 规则
hope_wisdom
发出的红包
实付
使用余额支付
点击重新获取
扫码支付
钱包余额 0

抵扣说明:

1.余额是钱包充值的虚拟货币,按照1:1的比例进行支付金额的抵扣。
2.余额无法直接购买下载,可以购买VIP、付费专栏及课程。

余额充值