• 大小: 558KB
    文件类型: .zip
    金币: 1
    下载: 0 次
    发布日期: 2021-06-05
  • 语言: C#
  • 标签: 数据库  C#  

资源简介

三层架构实现图书管理系统,基于C#和sql sever,50字50字

资源截图

代码片段和文件信息

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;

namespace BookManagement
{
    public partial class MainForm : Form
    {
        public MainForm()
        {
            InitializeComponent();
        }

        private void buttonAdd_Click(object sender EventArgs e)
        {
            if (ValidateInput())
            {
                string bookName = this.textBoxBookName.Text;
                string bookPrice = this.textBoxBookPrice.Text;
                string bookAuthor = this.textBoxBookAuthor.Text;
                BookManagementBLL.Book.AddBook(bookName bookPrice bookAuthor);
            }
        }

        public bool ValidateInput()
        {
            if (this.textBoxBookName.Text.Length == 0)
            {
                MessageBox.Show(“书名不能为空,请输入“);
                this.textBoxBookName.Focus();
                return false;
            }

            return true;
        }

        private void buttonDelete_Click(object sender EventArgs e)
        {
            if (ValidateInput())
            {
                BookManagementBLL.Book.DeleteBook(this.textBoxBookName.Text);
            }
        }

        private void buttonQuery_Click(object sender EventArgs e)
        {
            BookManagementBLL.Book.QueryBook(this.dataGridView1);
        }
    }
}

 属性            大小     日期    时间   名称
----------- ---------  ---------- -----  ----
     目录           0  2015-12-01 08:52  BookManagement\
     目录           0  2015-12-01 08:52  BookManagement\BookManagement\
     文件        3941  2015-12-08 08:10  BookManagement\BookManagement\BookManagement.csproj
     文件        8183  2015-12-08 09:30  BookManagement\BookManagement\MainForm.Designer.cs
     文件        1514  2015-12-08 09:30  BookManagement\BookManagement\MainForm.cs
     文件        5817  2015-12-08 09:30  BookManagement\BookManagement\MainForm.resx
     文件         498  2015-12-08 08:05  BookManagement\BookManagement\Program.cs
     目录           0  2015-12-01 08:52  BookManagement\BookManagement\Properties\
     文件        1384  2015-12-01 08:52  BookManagement\BookManagement\Properties\AssemblyInfo.cs
     文件        2879  2015-12-01 08:52  BookManagement\BookManagement\Properties\Resources.Designer.cs
     文件        5612  2015-12-01 08:52  BookManagement\BookManagement\Properties\Resources.resx
     文件        1100  2015-12-01 08:52  BookManagement\BookManagement\Properties\Settings.Designer.cs
     文件         249  2015-12-01 08:52  BookManagement\BookManagement\Properties\Settings.settings
     目录           0  2015-12-01 08:52  BookManagement\BookManagement\bin\
     目录           0  2015-12-01 08:52  BookManagement\BookManagement\bin\Debug\
     文件       10752  2015-12-08 09:30  BookManagement\BookManagement\bin\Debug\BookManagement.exe
     文件       26112  2015-12-08 09:30  BookManagement\BookManagement\bin\Debug\BookManagement.pdb
     文件       11600  2015-12-08 13:08  BookManagement\BookManagement\bin\Debug\BookManagement.vshost.exe
     文件        5120  2015-12-08 09:30  BookManagement\BookManagement\bin\Debug\BookManagementBLL.dll
     文件       13824  2015-12-08 09:30  BookManagement\BookManagement\bin\Debug\BookManagementBLL.pdb
     文件        9216  2015-12-08 09:30  BookManagement\BookManagement\bin\Debug\BookManagementDAL.dll
     文件       24064  2015-12-08 09:30  BookManagement\BookManagement\bin\Debug\BookManagementDAL.pdb
     文件      294912  2015-04-20 12:42  BookManagement\BookManagement\bin\Debug\MySql.Data.dll
     目录           0  2015-12-08 13:11  BookManagement\BookManagement\bin\Release\
     目录           0  2015-12-01 08:52  BookManagement\BookManagement\obj\
     目录           0  2015-12-01 08:52  BookManagement\BookManagement\obj\x86\
     目录           0  2015-12-01 08:52  BookManagement\BookManagement\obj\x86\Debug\
     文件         180  2015-12-08 09:30  BookManagement\BookManagement\obj\x86\Debug\BookManagement.MainForm.resources
     文件         180  2015-12-08 08:10  BookManagement\BookManagement\obj\x86\Debug\BookManagement.Properties.Resources.resources
     文件        1455  2015-12-08 13:08  BookManagement\BookManagement\obj\x86\Debug\BookManagement.csproj.FileListAbsolute.txt
     文件       10752  2015-12-08 09:30  BookManagement\BookManagement\obj\x86\Debug\BookManagement.exe
............此处省略52个文件信息

评论

共有 条评论