第一范文网 - 专业文章范例文档资料分享平台

大学生社团信息管理系统

来源:用户分享 时间:2025/7/23 9:09:18 本文由loading 分享 下载这篇文档手机版
说明:文章内容仅供预览,部分内容可能不全,需要完整文档或者需要复制内容,请下载word后使用。下载word有问题请添加微信号:xxxxxxx或QQ:xxxxxx 处理(尽可能给您提供完整文档),感谢您的支持与谅解。

当单击退出系统,该系统就会直接退出,相应的代码如下: private class ExitSystemAction implements ActionListener

{

}

}

public void actionPerformed(ActionEvent arg0) { System.exit(0);

5.2.2人员管理功能

(1)人员信息录入

单击人员信息录入,系统会跳出人员信息录入窗口,程序运行结果如图5.4所示:

图5.4 人员信息录入窗体运行结果

当用户单击录入按钮,则信息则会添加到数据库的nformation表中,当单击取消按钮,则文本框中的内容全部为空,可以重新输入。相应的代码如下:

人员信息录入代码: package com.zky.www.view;

public class Addpeople extends JInternalFrame {

private JLabel lbTip = new JLabel(\社团人员信息录入\private JLabel name = new JLabel(\姓名:\private JTextField inputName = new JTextField();

25

private JLabel sex = new JLabel(\性别:\private ButtonGroup group=new ButtonGroup(); private JRadioButton JRB1=new JRadioButton(\男\private JRadioButton JRB2=new JRadioButton(\女\private JLabel brithday=new JLabel(\出生日期:\private Choice choiceOne=new Choice(); private Choice choiceTwo=new Choice(); private Choice choiceThree=new Choice(); private JLabel address=new JLabel(\家庭住址:\private JTextField inputAdress=new JTextField(); private JLabel year=new JLabel(\年\private JLabel month=new JLabel(\月\private JLabel day=new JLabel(\日\private JLabel tel=new JLabel(\联系电话:\private JTextField inputTel=new JTextField(); private JLabel organization=new JLabel(\所在社团:\

private Choice choiceFour=new Choice();

private JLabel position=new JLabel(\担任职务:\private Choice choiceFive=new Choice(); private Button btnAdd=new Button(\录入\private Button btnCancel=new Button(\取消\Addpeople() {

JRB1.setActionCommand(\男\JRB2.setActionCommand(\女\this.setBounds(50, 90, 600, 450);; this.setTitle(\信息录入\this.setIconifiable(true); this.setClosable(true);

Container con=this.getContentPane(); con.setLayout(null);

26

lbTip.setBounds(0, 0, 600, 50); con.add(lbTip);

name.setBounds(80, 80, 50, 25); con.add(name);

inputName.setBounds(160, 80, 150, 23); con.add(inputName); sex.setBounds(80, 115, 50, 25); JRB1.setBounds(160, 115, 50, 25); JRB2.setBounds(260,115, 50, 25); con.add(sex); con.add(JRB1); con.add(JRB2);

brithday.setBounds(80, 150, 90, 25); choiceOne.setBounds(180, 150, 70, 25); year.setBounds(260, 150, 40, 25); choiceTwo.setBounds(290, 150, 70, 25); month.setBounds(370, 150, 40, 25); choiceThree.setBounds(400, 150, 70, 25); day.setBounds(500, 150, 30, 25); con.add(brithday); con.add(choiceOne); con.add(choiceTwo); con.add(choiceThree); con.add(year); con.add(month); con.add(day);

for(int i=1990;i<=2017;i++)

choiceOne.add(String.valueOf(i));

27

for(int j=1;j<=12;j++)

choiceTwo.add(String.valueOf(j));

for(int k=1;k<=31;k++)

choiceThree.add(String.valueOf(k));

group.add(JRB1); group.add(JRB2);

address.setBounds(80, 190, 80, 25); inputAdress.setBounds(180, 190, 150, 23); con.add(address); con.add(inputAdress); tel.setBounds(80, 230, 80, 25); inputTel.setBounds(180, 230, 150, 23); con.add(tel); con.add(inputTel);

organization.setBounds(80, 270, 80, 25); position.setBounds(80, 310, 80, 25); choiceFour.setBounds(180, 270, 150, 30); choiceFive.setBounds(180, 310, 150, 30); con.add(choiceFour); con.add(choiceFive); con.add(organization); con.add(position);

choiceFour.add(\青年志愿者协会\choiceFour.add(\篮球协会\choiceFour.add(\英语协会\choiceFour.add(\校学生会\choiceFive.add(\会长\choiceFive.add(\副会长\choiceFive.add(\社团成员\btnAdd.setBounds(150, 355, 60, 30); btnCancel.setBounds(270, 355, 60, 30);

28

搜索更多关于: 大学生社团信息管理系统 的文档
大学生社团信息管理系统.doc 将本文的Word文档下载到电脑,方便复制、编辑、收藏和打印
本文链接:https://www.diyifanwen.net/c9fo820256q2i4cx3q5al1oirv327pb00pmp_8.html(转载请注明文章来源)
热门推荐
Copyright © 2012-2023 第一范文网 版权所有 免责声明 | 联系我们
声明 :本网站尊重并保护知识产权,根据《信息网络传播权保护条例》,如果我们转载的作品侵犯了您的权利,请在一个月内通知我们,我们会及时删除。
客服QQ:xxxxxx 邮箱:xxxxxx@qq.com
渝ICP备2023013149号
Top