NetBarManageSystem/Form_zchy.cs

(开头部分) 2KB

这里只显示每个文件的开头 60 行。登录后可以解锁完整代码。

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 NetBarManageSystem_lihang
{
    public partial class Form_zchy : Form
    {
        //定义全局变量
        public From_main  fy;
        public Form_zchy()
        {
            InitializeComponent();
        }

        private void button2_Click(object sender, EventArgs e)
        {
            this.Close();
        }

      
        private void btn_qd_Click(object sender, EventArgs e)
        {
 
                //查询会员名是否重复
                string sql_cxyhm = "select * from cardInfo where cardNumber='" + this.txt_hykh.Text + "'";
                //执行查询
                DataTable table = sql_zsgc.cx(sql_cxyhm);

                if (table.Rows.Count > 0)
                {
                    MessageBox.Show("抱歉,此卡号已被注册.....", "系统提示", MessageBoxButtons.OK, MessageBoxIcon.Information);
                }

                else
                {
                    if (this.txt_mm.Text == this.txt_cfmm.Text)
                    {
                        //添加会员卡信息
                        string sql = "insert into cardInfo values ('" + this.txt_hykh.Text + "','" + this.txt_mm.Text + "'," + this.nud_cscz.Value + ",default)";
                        int result = sql_zsgc.zsg(sql);
                        if (result >= 1)
                        {
                            MessageBox.Show("恭喜您注册会员成功!", "系统提示", MessageBoxButtons.OK, MessageBoxIcon.Information);
                            //向数据库添加操作记录
                            string sql_zc = "insert into czInfo values ('会员卡:" + this.txt_hykh.Text + "注册成功,初始充值" + this.nud_cscz.Value+ "元!',default)";
                            int n = sql_zsgc.zsg(sql_zc);
                            //调用查询操作记录方法刷新操作记录

                            fy.cxczjl();

                            //注册成功刷新会员卡窗体的显示(会卡窗体打开了就刷新,没打开就不刷新)
                            if (fy.hyk != null && fy.hyk.IsDisposed == false)
                            {
                                fy.hyk.hykload() ;
后面还有 22 行代码,解锁后查看完整代码

24 小时内免费解锁 3 个项目,之后 1 算力/个。 规则说明

AI 解读 AI

登录后可用,每次 10 算力,解读结果公开显示在下面。

还没有人解读过这个文件。