文档下载 文档下载导航
设为首页 | 加入收藏
搜索 请输入内容:  
 导航当前位置: 文档下载 > 所有分类 > IT/计算机 > 学生管理系统(JAVA-Mysql)
侵权投诉

学生管理系统(JAVA-Mysql)


import java.awt.Toolkit;
import java.sql.Connection;
import java.sql.DriverManager;
import java.sql.ResultSet;
import java.sql.SQLException;

import javax.swing.ButtonGroup;
import javax.swing.JOptionPane;

import com.mysql.jdbc.Statement;

public class system extends javax.swing.JFrame {

static int m_Level = -1;
public system() {
super("登录系统");
initComponents();
//然后设置你编写的窗口的初始位置,也就是在中间,
int width = Toolkit.getDefaultToolkit().getScreenSize().width;
int height = Toolkit.getDefaultToolkit().getScreenSize().height;
this.setLocation(width / 2 - 200, height / 2 - 150);
}

@SuppressWarnings("unchecked")
private void initComponents() {

jLabel1 = new javax.swing.JLabel();
jRadioButton1 = new javax.swing.JRadioButton();
jRadioButton2 = new javax.swing.JRadioButton();
jRadioButton3 = new javax.swing.JRadioButton();
jLabel2 = new javax.swing.JLabel();
jTextField1 = new javax.swing.JTextField();
jLabel3 = new javax.swing.JLabel();
jButton1 = new javax.swing.JButton();
jButton2 = new javax.swing.JButton();
jPassword = new javax.swing.JPasswordField();

ButtonGroup bg = new ButtonGroup();
bg.add(jRadioButton1);
bg.add(jRadioButton2);
bg.add(jRadioButton3);
setDefaultCloseOperation(javax.swing.WindowConstants.EXIT_ON_CLOSE);

jLabel1.setFont(new java.awt.Font("宋体", 0, 36)); // NOI18N
jLabel1.setForeground(new java.awt.Color(0, 0, 0));
jLabel1.setText("学生信息管理系统");
//jLabel1.
jRadioButton1.setForeground(new java.awt.Color(0, 0, 0));
jRadioButton1.setText("学生");
jRadioButton1.addActionListener(new java.awt.event.ActionListener() {
public void actionPerformed(java.awt.event.ActionEvent evt) {
jRadioButton1ActionPerformed(evt);
}
});

jRadioButton2.setForeground(new java.awt.Color(0, 0, 0));
jRadioButton2.setText("老师");
jRadioButton2.addActionListener(new java.awt.event.ActionListener() {
public void actionPerformed(java.awt.event.ActionEvent evt) {
jRadioButton2ActionPerformed(evt);
}
});

jRadioButton3.setForeground(new java.awt.Color(0, 0, 0));
jRadioButton3.setText("管理员");
jRadioButton3.addActionListener(new java.awt.event.ActionListener() {
public void actionPerformed(java.awt.event.ActionEvent evt) {
jRadioButton3ActionPerformed(evt);
}
});
jLabel2.setFont(new java.awt.Font("宋体", 0, 24)); // NOI18N
jLabel2.setForeground(new java.awt.Color(0, 0, 0));
jLabel2.setText("帐号:");

jLabel3.setFont(new java.awt.Font(

第1页

你可能喜欢

  • 管理系统SQL
  • 成绩管理系统java
  • MySQL命令
  • 学生信息管理系统java课程设计
  • 复习笔记
  • Java基础
  • mysql教程

热门文档

相关文档

站点地图 | 文档上传 | 侵权投诉 | 手机版
本站所有资源均来自互联网,本站只负责收集和整理,均不承担任何法律责任,如有侵权等其它行为请联系我们.
文档下载 Copyright 2013 doc.guandang.net All Rights Reserved.  -  email