• 大小: 5.55MB
    文件类型: .zip
    金币: 1
    下载: 0 次
    发布日期: 2023-11-03
  • 语言: C#
  • 标签: C#  毕业设计  

资源简介

本毕业设计是作者2015年6月份毕业自己写的,数据库用的是mysql,用C#语言实现的,系统实现起来还是不难的,比较适合大四狗,你懂得!

资源截图

代码片段和文件信息

using System;
using System.Collections.Generic;
using System.ComponentModel;
using System.Data;
using System.Drawing;

using System.Linq;
using System.Text;
using System.Windows.Forms;
using WindowsFormsApplication1.Bean.UserBean;
using WindowsFormsApplication1.Common.DAO;
using WindowsFormsApplication1.UserModule;
using WindowsFormsApplication1.RemindModule;

namespace WindowsFormsApplication1
{
    public partial class LoginForm : Form
    {
        DataDAO dataDAO = null;                //连接数据库

        public LoginForm()                     //构造函数
        {
            dataDAO = new DataDAO();
            InitializeComponent();
        }

        private void button1_Click(object sender EventArgs e)
        {
            RegistForm registForm = new RegistForm();
            registForm.Show();

        }

        private void LoginForm_Load(object sender EventArgs e)
        {
            //初始化登陆界面的下拉列表
            viewCBx.DropDownstyle = ComboBoxstyle.DropDownList;                                                      //禁止在文本编辑框输入数据的组合框样式
            String[] newitem = { “系统管理员“ “一般管理员“ “用户“ };
            viewCBx.Items.AddRange(newitem);
            viewCBx.SelectedIndex = 1;
        }

        private void outBtn_Click(object sender EventArgs e)
        {
            this.Dispose();
        }

        private void label1_Click_1(object sender EventArgs e)
        {

        }

        private void inBtn_Click(object sender EventArgs e)
        {
            //对必要输入的文本框进行初始化
            userNameTxt.BackColor = Color.White;
            userNameTxt.ForeColor = Color.Black;
            passWordTxt.BackColor = Color.White;
            passWordTxt.ForeColor = Color.Black;

            T_user user = new T_user();
            if (““.Equals(userNameTxt.Text.Trim()))
            {
                MessageBox.Show(“请输入登录名称!“);
                userNameTxt.BackColor = Color.Red;
                userNameTxt.ForeColor = Color.White;
                userNameTxt.Focus();
                return;
            }
            if (““.Equals(passWordTxt.Text.Trim()))
            {
                MessageBox.Show(“请输入登录密码!“);
                passWordTxt.BackColor = Color.Red;
                passWordTxt.ForeColor = Color.White;
                passWordTxt.Focus();
                return;
            }


            user.User_name = userNameTxt.Text.Trim();
            user.User_pasw = passWordTxt.Text.Trim();


            String searchSql = “select user_permission from tb_user where user_name = ‘“ + user.User_name + “‘ and user_pasw = ‘“ + passWordTxt.Text.Trim() + “‘“;
            DataSet dataSet = dataDAO.search(searchSql);

            if (dataSet.Tables[“Table“].Rows.Count == 0)
            {
                MessageBox.Show(“用户名或密码错误!“);
                return;
            }

            int permission = 0;
            if (“系统管理员“.Equals(viewCBx.Text.Trim()))
    

 属性            大小     日期    时间   名称
----------- ---------  ---------- -----  ----
     目录           0  2015-05-22 13:27  1111111111111\
     目录           0  2015-05-22 13:28  1111111111111\WindowsFormsApplication1\
     文件        1446  2015-05-19 11:40  1111111111111\WindowsFormsApplication1.sln
     文件       44544  2015-05-20 10:20  1111111111111\WindowsFormsApplication1.suo
     文件         732  2015-04-08 17:52  1111111111111\WindowsFormsApplication1\app.config
     目录           0  2015-05-22 13:27  1111111111111\WindowsFormsApplication1\Bean\
     目录           0  2015-05-22 13:27  1111111111111\WindowsFormsApplication1\Bean\BikeBean\
     文件        1799  2015-03-27 11:00  1111111111111\WindowsFormsApplication1\Bean\BikeBean\T_bike.cs
     目录           0  2015-05-22 13:27  1111111111111\WindowsFormsApplication1\Bean\CommentBean\
     文件        1514  2015-04-13 09:18  1111111111111\WindowsFormsApplication1\Bean\CommentBean\T_comment.cs
     目录           0  2015-05-22 13:27  1111111111111\WindowsFormsApplication1\Bean\CompanyBean\
     文件        1728  2015-04-15 14:25  1111111111111\WindowsFormsApplication1\Bean\CompanyBean\T_company.cs
     目录           0  2015-05-22 13:27  1111111111111\WindowsFormsApplication1\Bean\ManageBean\
     文件        1425  2015-03-30 15:30  1111111111111\WindowsFormsApplication1\Bean\ManageBean\T_manage.cs
     目录           0  2015-05-22 13:27  1111111111111\WindowsFormsApplication1\Bean\MoneyBean\
     文件        1425  2015-04-08 19:08  1111111111111\WindowsFormsApplication1\Bean\MoneyBean\T_rent_money.cs
     目录           0  2015-05-22 13:27  1111111111111\WindowsFormsApplication1\Bean\RentBean\
     文件        1608  2015-03-27 11:05  1111111111111\WindowsFormsApplication1\Bean\RentBean\T_rent.cs
     目录           0  2015-05-22 13:27  1111111111111\WindowsFormsApplication1\Bean\ReturnBean\
     文件        1430  2015-04-14 13:35  1111111111111\WindowsFormsApplication1\Bean\ReturnBean\T_return_bike.cs
     目录           0  2015-05-22 13:27  1111111111111\WindowsFormsApplication1\Bean\UserBean\
     文件        9589  2015-05-18 16:03  1111111111111\WindowsFormsApplication1\Bean\UserBean\T_user.cs
     目录           0  2015-05-22 13:27  1111111111111\WindowsFormsApplication1\Bean\UserRentBean\
     文件        1254  2015-04-24 14:09  1111111111111\WindowsFormsApplication1\Bean\UserRentBean\T_user_rent.cs
     目录           0  2015-05-22 13:27  1111111111111\WindowsFormsApplication1\BikeModule\
     文件        6450  2015-05-19 13:57  1111111111111\WindowsFormsApplication1\BikeModule\EditForm.cs
     文件       14096  2015-04-15 16:43  1111111111111\WindowsFormsApplication1\BikeModule\EditForm.Designer.cs
     文件       25415  2015-04-15 16:43  1111111111111\WindowsFormsApplication1\BikeModule\EditForm.resx
     目录           0  2015-05-22 13:27  1111111111111\WindowsFormsApplication1\bin\
     目录           0  2015-05-22 13:27  1111111111111\WindowsFormsApplication1\bin\Debug\
     目录           0  2015-05-22 13:27  1111111111111\WindowsFormsApplication1\bin\Debug\Database\
............此处省略155个文件信息

评论

共有 条评论