酒店管理C#项目(推荐)


业务很清晰,结业时的项目,还是很不错的,大家多多支持! 初学者也非常值得下载!可以学习很多东西的!东西都很齐全。。
资源截图
代码片段和文件信息
using System;
using System.Collections.Generic;
using System.ComponentModel;
using System.Data;
using System.Drawing;
using System.Linq;
using System.Text;
using System.Threading.Tasks;
using System.Windows.Forms;
using System.Data.SqlClient;

namespace WindowsFormsApplication1
{
    public partial class AddGoods : Form
    {
        public AddGoods()
        {
            InitializeComponent();
        }
        static string sql = @“Data Source=.;Initial Catalog=International Fashion Hotel;Integrated Security=True“;
        SqlConnection con = new SqlConnection(sql);
        private void label2_Click(object sender EventArgs e)
        {

        }

        private void label1_Click(object sender EventArgs e)
        {

        }

        private void button2_Click(object sender EventArgs e)
        {
            textBox1.Text = ““;
            textBox2.Text = ““;
            textBox3.Text = ““;
            comboBox1.SelectedIndex = 0;
            textBox4.Text = ““;
            textBox5.Text = ““;
        }
      
        private void button1_Click(object sender EventArgs e)
        {
            try
            {
                con.Open();
                int name = 0;
                if (comboBox1.Text == “槟榔“)
                {
                    name = 3;
                }
                else if (comboBox1.Text == “食品“)
                {
                    name = 2;
                }
                else if (comboBox1.Text == “饮料“)
                {
                    name = 4;
                }
                else if (comboBox1.Text == “烟酒“)
                {
                    name = 1;
                }
                else if (comboBox1.Text == “日用品“)
                {
                    name = 5;
                }

                foreach (Control item in Controls)
                {
                    if (item is TextBox)
                    {
                        if (item.Text==“请输入正确的值“||item.Text==““)
                        {
                            MessageBox.Show(“请填写完整信息“ “提示“ MessageBoxButtons.OK MessageBoxIcon.Asterisk);
                            return;
                        }

                    }
                }

                if (Convert.ToDouble(textBox2.Text)>Convert.ToDouble(textBox3.Text))
                {
                    MessageBox.Show(“预售价格不能小于进价““提示“MessageBoxButtons.OKMessageBoxIcon.Asterisk);
                    return;
                }
                string ii = string.Format(@“insert into GoodsInfo(GoodsName Unit InPrice OutPrice GoodsType Inventory)
values(‘{0}‘‘{1}‘‘{2}‘‘{3}‘‘{4}‘‘{5}‘)“ textBox1.Text textBox5.Text textBox2.Text textBox3.Text name textBox4.Text);
                SqlCommand ser = new SqlCommand(ii con);
                int yy = (int)ser.ExecuteNonQuery();
                if (yy > 0)
                {
                    MessageBox.Show(“添加成功“ “

 属性            大小     日期    时间   名称
----------- ---------  ---------- -----  ----
     文件     5242880  2018-10-22 08:26  International Fashion Hotel.mdf
     文件     1048576  2018-10-22 08:26  International Fashion Hotel_log.ldf
     目录           0  2018-09-23 12:40  最终项目!
     文件       13185  2018-08-19 14:24  最终项目!1806项目功能.xlsx
     目录           0  2018-09-05 16:31  最终项目!International Fashion Hotel
     文件        1041  2018-08-05 15:42  最终项目!International Fashion HotelInternational Fashion Hotel.sln
     文件      360960  2018-10-22 08:25  最终项目!International Fashion HotelInternational Fashion Hotel.v12.suo
     目录           0  2018-10-25 11:59  最终项目!International Fashion HotelWindowsFormsApplication1
     文件       12003  2018-09-21 16:05  最终项目!International Fashion HotelWindowsFormsApplication1AddGoods.cs
     文件       16100  2018-09-21 16:05  最终项目!International Fashion HotelWindowsFormsApplication1AddGoods.designer.cs
     文件       54461  2018-09-21 16:05  最终项目!International Fashion HotelWindowsFormsApplication1AddGoods.resx
     文件        9891  2018-09-21 16:38  最终项目!International Fashion HotelWindowsFormsApplication1AddRoom.cs
     文件       15912  2018-09-21 16:38  最终项目!International Fashion HotelWindowsFormsApplication1AddRoom.designer.cs
     文件       84217  2018-09-21 16:38  最终项目!International Fashion HotelWindowsFormsApplication1AddRoom.resx
     文件        4256  2018-09-21 16:07  最终项目!International Fashion HotelWindowsFormsApplication1AddRoomType.cs
     文件        9283  2018-09-21 16:07  最终项目!International Fashion HotelWindowsFormsApplication1AddRoomType.designer.cs
     文件       13668  2018-09-21 16:07  最终项目!International Fashion HotelWindowsFormsApplication1AddRoomType.resx
     文件       10052  2018-09-21 16:08  最终项目!International Fashion HotelWindowsFormsApplication1AddStaff.cs
     文件       15352  2018-09-21 16:08  最终项目!International Fashion HotelWindowsFormsApplication1AddStaff.designer.cs
     文件       13668  2018-09-21 16:08  最终项目!International Fashion HotelWindowsFormsApplication1AddStaff.resx
     文件        9186  2018-09-21 16:09  最终项目!International Fashion HotelWindowsFormsApplication1AddVip.cs
     文件       18497  2018-09-21 16:09  最终项目!International Fashion HotelWindowsFormsApplication1AddVip.designer.cs
     文件       51209  2018-09-21 16:09  最终项目!International Fashion HotelWindowsFormsApplication1AddVip.resx
     文件         187  2018-08-05 15:42  最终项目!International Fashion HotelWindowsFormsApplication1App.config
     目录           0  2018-09-05 16:31  最终项目!International Fashion HotelWindowsFormsApplication1in
     目录           0  2018-10-25 11:56  最终项目!International Fashion HotelWindowsFormsApplication1inDebug
     文件     2738176  2016-05-18 18:13  最终项目!International Fashion HotelWindowsFormsApplication1inDebugCSkin.dll
     文件     3559424  2018-10-22 08:25  最终项目!International Fashion HotelWindowsFormsApplication1inDebugWindowsFormsApplication1.exe
     文件         187  2018-08-05 15:42  最终项目!International Fashion HotelWindowsFormsApplication1inDebugWindowsFormsApplication1.exe.config
     文件      679424  2018-10-22 08:25  最终项目!International Fashion HotelWindowsFormsApplication1inDebugWindowsFormsApplication1.pdb
     文件       24224  2018-10-22 08:25  最终项目!International Fashion HotelWindowsFormsApplication1inDebugWindowsFormsApplication1.vshost.exe
............此处省略190个文件信息

版权声明:本文内容由互联网用户自发贡献,该文观点仅代表作者本人。本站仅提供信息存储空间服务,不拥有所有权,不承担相关法律责任。如发现本站有涉嫌抄袭侵权/违法违规的内容, 请发送邮件举报,一经查实,本站将立刻删除。

发表评论

评论列表(条)