示例#1
0
        private void Frm_Main_Buyde_Load(object sender, EventArgs e)
        {
            //toolStrip1.ForeColor = Color.Transparent;

            Frm_Login f = new Frm_Login();

            Icon = f.Icon;

            //添加头像
            tjtx(sender, e);

            //Frm_LiuLanComPa ff = new Frm_LiuLanComPa();
            //create_window("Frm_LiuLanCom", ff);

            tolab_UserName.Text = love.denglu_username == string.Empty ? "欢迎 b " : "欢迎 " + love.denglu_username + " 回来";
            time.Enabled        = true;
            tolab_dltime.Text   = "登陆时间:" + DateTime.Now.ToString();
            time.Tick          += new EventHandler(time_Tick);
            //locx = pan_windows.Location.X;
            //locy = pan_windows.Location.Y;

            //love.meihua(this);
            Frm_LiuLanComDat fff = new Frm_LiuLanComDat();

            fff.Dock = DockStyle.Fill;
            create_window("Frm_LiuLanComDat", fff);

            //写上余额
            sxje(sender, e);
            //库存
        }
        private void Frm_LiuLanCom_Load(object sender, EventArgs e)
        {
            btn_add.Visible = false;

            foreach (Control i in Controls)
            {
                i.Anchor = AnchorStyles.None;
            }
            Frm_Login f = new Frm_Login();

            Icon       = f.Icon;
            AutoScroll = true;

            commodity commodity = new commodity();
            DataTable d         = commodity.allcommodity();

            allcount = d.Rows.Count;//记录下商品的总行数
            for (int i = 0; i < allcount; i++)
            {
                comrows.Add(i);//循环添加行数到商品行号集合
            }
            //Text = comrows.Count.ToString();//查看行数

            //程序进来就给看一个商品
            //Random sjs = new Random();
            //int dangqian = sjs.Next(0, comrows.Count);//记录下随机到的行号
            //yigecom(comrows[dangqian]);//pannel控件显示某行的商品
            //comrows.Remove(comrows[dangqian]);//每次都要把用过的值给清理掉
            while (log)
            {
                btn_add_Click(sender, e);
            }
        }
        /// <summary>
        /// 刷新库存数
        /// </summary>
        /// <param name="sender"></param>
        /// <param name="e"></param>
        //public void sxspcount(object sender, EventArgs e)
        //{
        //    string sql = string.Format("select COUNT(*) from commodity where username = '******'", love.denglu_username);
        //    lab_shoumai.Text ="您正在出售 "+ sqlHelper.ExecutedataTable(sql, CommandType.Text, null).Rows[0][0].ToString() +" 件商品";
        //}

        private void Frm_Main_Sellde_Load(object sender, EventArgs e)
        {
            Frm_Login f = new Frm_Login();

            Icon = f.Icon;

            //添加头像
            tjtx(sender, e);

            love.meihua(this);


            tolab_UserName.Text = love.denglu_username == string.Empty ? "欢迎 a " : "欢迎 " + love.denglu_username + " 回来";
            time.Enabled        = true;
            tolab_dltime.Text   = "登陆时间:" + DateTime.Now.ToString();
            time.Tick          += new EventHandler(time_Tick);

            //写上余额
            sxje(sender, e);//刷新金额

            Frm_ComXiangXI fff = new Frm_ComXiangXI();

            fff.Dock = DockStyle.Fill;
            create_window("Frm_ComXiangXI", fff);
        }
示例#4
0
        //结束
        #endregion

        private void Frm_login_Load(object sender, EventArgs e)//窗体诞生之前就会执行的方法     //Load:装入
        {
            if (File.Exists(Application.StartupPath + "\\zhmmdll"))
            {
                //创建文件流
                FileStream   fs = new FileStream(Application.StartupPath + "\\zhmmdll", FileMode.Open);
                StreamReader sr = new StreamReader(fs); //打算阅读它
                string       dz = sr.ReadToEnd();       //收集到文件流中的所有数据
                txt_username.Text = dz.Substring(dz.IndexOf("zh") + 2, dz.LastIndexOf("zh") - 2);
                txt_password.Text = dz.Substring(dz.IndexOf("mm") + 2);
                sr.Close(); fs.Close();//记得先关闭阅读流,然后在关闭文件流,两个都要关闭,不要浪费系统的内存
            }

            //lab_tip.BackColor = Color.FromArgb(255, 253, 238);
            //lab_dl.BackColor = lab_tip.BackColor;
            //lab_zc.BackColor = lab_tip.BackColor;
            //lkb_wangjipwd.BackColor = lab_tip.BackColor;
            //lkb_xinyonhu.BackColor = lab_tip.BackColor;
            //Love_Shopping.BackColor = lab_tip.BackColor;

            btn_clear.BackColor     = Color.FromArgb(255, 253, 238);
            btn_denlu.BackColor     = btn_clear.BackColor;
            btn_zhuce.BackColor     = btn_clear.BackColor;
            btn_zc_tuichu.BackColor = btn_clear.BackColor;
            btn_pic.BackColor       = btn_clear.BackColor;
            btn_exit.BackColor      = btn_clear.BackColor;
            btn_zc_tuichu.BackColor = btn_clear.BackColor;
            btn_zc_clear.BackColor  = btn_clear.BackColor;

            foreach (Control item in Controls)
            {
                if (item is Label || item is CheckBox || item is PictureBox || item is GroupBox || item is Button || item is Panel)
                {
                    item.BackColor = Color.Transparent;
                }
            }

            love.buyde_id = txt_username.Text;
            foreach (Control i in Controls)
            {
                i.Anchor = AnchorStyles.None;
            }

            Frm_Login f = new Frm_Login();

            Icon = f.Icon;

            //txt_password.Text = txt_username.Text = "b";
            pan_zhuce.Visible         = false;               //首先把注册界面隐藏
            pic_photo.BorderStyle     = BorderStyle.Fixed3D; //头像边框为三维边框
            rad_sellde.Checked        = true;                //默认注册成为卖家
            txt_password.PasswordChar = '*';                 //遮挡密码
            txt_zc_pwd1.PasswordChar  = txt_password.PasswordChar;
            txt_zc_pwd2.PasswordChar  = txt_password.PasswordChar;
            tiemzou();
        }
示例#5
0
        private void Frm_UserOrther_Load(object sender, EventArgs e)//窗口诞生就会这里面的代码,load装入
        {
            //#region 测试期间为控件们赋值
            //foreach (Control i in Controls)
            //{
            //    if (i is TextBox)
            //    {
            //        if (i.Name == "txt_telephone")
            //        {
            //            i.Text = "123";
            //            continue;
            //        }
            //        i.Text = "测试期间为控件们赋值";
            //    }
            //}
            //#endregion
            foreach (Control i in Controls)
            {
                i.Anchor = AnchorStyles.None;
            }
            love.meihua(this);

            hui = txt_mibaowenti.ForeColor; //记录下灰色字体
            txt_mibaodaan.ForeColor = hui;  //让答案框的字体和问题框也一样

            Frm_Login f = new Frm_Login();

            Icon = f.Icon;

            rad_man.Checked = true;                          //默认选中了男性
            if (love_DAL.love.denglu_IsSelldeOrBuyde == "卖") //判断是买家还是卖家
            {
                lab_dizhi.Text = "发货地址";
            }
            else
            {
                lab_dizhi.Text   = "收货地址";
                lab_datishi.Text = "亲爱的买家,请填写您的详细信息";
            }

            //下面只是简单的初始化
            string[] shen       = { "湖南省", "北京" };
            string[] shi        = { "娄底市", "湘潭市" };
            string[] xiangzheng = { "娄星区", "其它" };
            cmb_sheng.Items.AddRange(shen);
            cmb_shi.Items.AddRange(shi);
            cmb_xiangzhen.Items.AddRange(xiangzheng);

            cmb_sheng.SelectedIndex     = 0;//设置显示的是第几个选项
            cmb_shi.SelectedIndex       = 0;
            cmb_xiangzhen.SelectedIndex = 0;

            updateyzm();//验证码赋值
        }
示例#6
0
        private void Frm_ComXiangXI_Load(object sender, EventArgs e)
        {
            MinimumSize = new Size(1087, 637);//因为它小于这个值显示不好
            foreach (Control i in Controls)
            {
                i.Anchor = AnchorStyles.None;
            }
            Frm_Login f = new Frm_Login();

            Icon = f.Icon;
            update_dgv();//刷新商品表数据

            //为combox物流公司填入信息
            string[] wuliu =
            {
                "请选择",     "顺丰",   "中通",    "圆通",   "申通",        "韵达",  "汇通",   "天天",   "中国邮政",  "EMS",  "宅急送",  "德邦物流",  "国通快递", "佳吉快运", "中铁快运", "速尔快递",
                "中邮物流",    "能达速递", "全峰快递",  "快捷速递", "联邦快递FedEx", "DHL", "优速快递", "天地华宇", "全日通快递", "信丰物流", "新邦物流", "UPS快递",
                "TNT国际快递", "盛辉物流", "中外运全一", "佳怡物流", "飞康达物流",     "联昊通快递"
            };
            cmb_wuliugongsi.Items.AddRange(wuliu);

            cmb_wuliugongsi.FlatStyle = FlatStyle.Popup;
            //cmb_wuliugongsi.DropDownStyle = ComboBoxStyle.DropDownList;
            dgv_data.RowsDefaultCellStyle.Alignment          = DataGridViewContentAlignment.MiddleCenter; //行居中
            dgv_data.ColumnHeadersDefaultCellStyle.Alignment = DataGridViewContentAlignment.MiddleCenter; //列居中
            dgv_data.AllowUserToResizeColumns = false;                                                    //不允许更改列宽
            hui = txt_orther.ForeColor;                                                                   //记录下灰色字体

            dgv_data.AutoResizeColumn(7);                                                                 //时间列指定自动适应宽度

            lab_daico.Visible = lab_pic_xiao1.Visible = lab_pic_xiao2.Visible = lab_pic_xiao3.Visible = false;

            foreach (Control item in Controls)
            {
                if (item is Label || item is CheckBox || item is PictureBox || item is GroupBox || item is Button || item is Panel)
                {
                    item.BackColor = Color.Transparent;
                }
                if (item is PictureBox)
                {
                    PictureBox bbb = (PictureBox)item;
                    bbb.BorderStyle = BorderStyle.None;
                }
                if (item is Button)
                {
                    Button bbb = (Button)item;
                    SetBtnStyle(bbb);
                }
            }

            SetBtnStyle(btn_addorther);
            SetBtnStyle(btn_allcolor);
            SetBtnStyle(btn_list_clear);
        }
示例#7
0
        private void Frm_LiuLanComDat_Load(object sender, EventArgs e)
        {
            //dgv_com.RowHeadersVisible = false;//不出现开头的空白边
            //dgv_com.ColumnHeadersVisible = false;//不出现开头的空白边
            totxt_yeshu.Text = hangshu.ToString();
            string[] y = { "1", "2", "3", "4", "5", "6", "7", "8", "9", "10", "11", "12", "13", "14", "15", "16", "17", "18", "19", "20" };
            //tocmb_yeshu.Items.AddRange(y);
            //tocmb_yeshu.DropDownStyle = ComboBoxStyle.DropDownList;
            //tocmb_yeshu.SelectedIndex = 9;
            //tocmb_yeshu.FlatStyle = FlatStyle.Standard;

            btn_dgv_wushujutip.Visible = false;

            Frm_Login f = new Frm_Login();

            Icon = f.Icon;

            MinimumSize = new Size(1132, 607);
            foreach (Control item in Controls)
            {
                item.Anchor = AnchorStyles.None;
            }

            rab_xiangxi.ReadOnly    = true;//不允许更改卖家介绍
            rab_xiangxi.BorderStyle = BorderStyle.FixedSingle;
            commodity com = new commodity();

            dgv_com.RowsDefaultCellStyle.Alignment          = DataGridViewContentAlignment.MiddleCenter;
            dgv_com.ColumnHeadersDefaultCellStyle.Alignment = DataGridViewContentAlignment.MiddleCenter;
            dgv_com.DataSource = com.selldecommdity();

            dgv_com.AutoGenerateColumns      = false;
            dgv_com.AllowUserToResizeColumns = false;
            dgv_com.AllowUserToDeleteRows    = false;
            dgv_com.AllowUserToAddRows       = false;
            dgv_com.ReadOnly    = true;
            dgv_com.MultiSelect = false;

            //下面分页的行、页记得不要放到分页方法里面去,因为每次执行都会初始化
            CurrentRow  = 0; //当前行为0
            CurrentPage = 1; //当前页为1

            fenyegongneng();

            dgv_com.Columns[0].HeaderText = "商品名";
            dgv_com.Columns[1].HeaderText = "售价";
            dgv_com.Columns[2].HeaderText = "包邮";
            dgv_com.Columns[3].HeaderText = "快递";
            dgv_com.Columns[4].HeaderText = "库存";
            dgv_com.Columns[5].HeaderText = "月销量";
            dgv_com.Columns[6].HeaderText = "生产地";

            love.meihua(this);
        }
        private void frm_ChongZhi_Load(object sender, EventArgs e)
        {
            Frm_Login f = new Frm_Login();

            Icon = f.Icon;
            updatejine();//刷新金额
            love.meihua(this);
            foreach (Control i in Controls)
            {
                i.Anchor = AnchorStyles.None;
            }
        }
示例#9
0
        private void Frm_Restore_Load(object sender, EventArgs e)
        {
            MinimumSize     = new Size(780, 462);
            FormBorderStyle = FormBorderStyle.FixedSingle;
            foreach (Control i in Controls)
            {
                i.Anchor = AnchorStyles.None;
            }
            Frm_Login f = new Frm_Login();

            Icon = f.Icon;
            tiemzou();
        }
示例#10
0
        private void Frm_WangJiPwd_Load(object sender, EventArgs e)//初始化窗体事件
        {
            txt_username.Text = love.denglu_username;
            foreach (Control i in Controls)
            {
                i.Anchor = AnchorStyles.None;
            }
            Frm_Login f = new Frm_Login();

            Icon = f.Icon;
            txt_okpwd.PasswordChar  = '*';
            txt_newpwd.PasswordChar = '*';
            updateyzm(); //刷新验证码
        }
示例#11
0
        private void Frm_WangJiPwd_Load(object sender, EventArgs e)//初始化窗体事件
        {
            foreach (Control i in Controls)
            {
                i.Anchor = AnchorStyles.None;
            }
            txt_okpwd.PasswordChar  = '*';
            txt_newpwd.PasswordChar = '*';
            updateyzm(); //刷新验证码
            Frm_Login f = new Frm_Login();

            Icon = f.Icon;
            ckb_isordneglu.Checked = true;
        }
示例#12
0
        private void Frm_Backup_Load(object sender, EventArgs e)
        {
            foreach (Control i in Controls)
            {
                i.Anchor = AnchorStyles.None;
            }
            tiemzou();
            Frm_Login f = new Frm_Login();

            Icon = f.Icon;
            foreach (Control item in Controls)
            {
                if (item is Label || item is CheckBox || item is PictureBox || item is GroupBox || item is Button || item is Panel)
                {
                    item.BackColor = Color.Transparent;
                }
            }
        }
示例#13
0
        private void Frm_Sellde_Load(object sender, EventArgs e)//窗体诞生时就会执行的函数
        {
            //cmb_kuaidi.DropDownStyle = ComboBoxStyle.DropDownList;
            cmb_kuaidi.FlatStyle = FlatStyle.Flat;

            foreach (Control i in Controls)
            {
                i.Anchor = AnchorStyles.None;
            }
            Frm_Login f = new Frm_Login();

            Icon = f.Icon;

            //string sql = "select comid,name,shoujia,kuadi,kucun,isbaoyou from commodity";
            string    sql = "select comid 商品ID,name 商品名,shoujia 售价,isbaoyou 是否包邮,kuadi 快递,kucun 库存 from commodity";
            DataTable d   = sqlHelper.ExecutedataTable(sql, CommandType.Text, null);

            dgv_yulan.DataSource = d;

            dgv_yulan.AllowUserToAddRows = false;//不允许用户添加行

            //在这个地方把快递的列表给初始化一下
            string[] kuadi = { "顺丰", "中国邮政", "EMS", "中通", "圆通", "申通", "韵达", "汇通", "天天", "宅急送", "其它比较知名快递", " 德邦物流", "国通快递", "佳吉快运", "中铁快运", "速尔快递", "中邮物流", "能达速递", "全峰快递快捷速递", "联邦快递FedEx", "DHL", "优速快递", "天地华宇", "全日通快递", "信丰物流", "新邦物流", "UPS快递", "TNT国际快递", "盛辉物流", "中外运全一", "佳怡物流", "飞康达物流", "联昊通快递" };
            cmb_kuaidi.Items.AddRange(kuadi);//添加好上面的快递到列表选项里面去
            //cmb_kuaidi.SelectedIndex = 0;


            if (d.Rows.Count == 0)
            {
                btn_clear_Click(sender, e);
                lab_id.Visible = false;
            }
            //tiemzou();//启动左右循环动画

            dgv_yulan.RowsDefaultCellStyle.Alignment          = DataGridViewContentAlignment.MiddleCenter; //行居中
            dgv_yulan.ColumnHeadersDefaultCellStyle.Alignment = DataGridViewContentAlignment.MiddleCenter; //列居中
            dgv_yulan.AllowUserToResizeColumns = false;                                                    //不允许更改列宽



            love.meihua(this);
        }
        private void Frm_SelldeGoods_Load(object sender, EventArgs e)
        {
            Frm_Login f = new Frm_Login();

            Icon = f.Icon;
            foreach (Control i in Controls)
            {
                if (i == pan_goods)
                {
                    continue;
                }
                i.Anchor = AnchorStyles.None;
            }
            sckjmen();
            tiemzou();
            //tiemzou2();
            lab_tip1.Left = pan_goods.Left;
            love.meihua(this);
            lab_tip1.Text = string.Format("爱尚购公告:亲爱的 {0} ,多添加商品可以增添收益噢!O(≧口≦)O", love.denglu_username == string.Empty ? "a" : love.denglu_username);

            //pan_goods.BackColor = Color.Transparent;
        }
        private void Frm_BuydeGoods_Load(object sender, EventArgs e)
        {
            Frm_Login f = new Frm_Login();

            Icon = f.Icon;
            foreach (Control i in Controls)
            {
                if (i == pan_goods)
                {
                    continue;
                }
                i.Anchor = AnchorStyles.None;
            }
            sckjmen();
            foreach (Control item in Controls)
            {
                if (item is Label || item is CheckBox || item is PictureBox || item is GroupBox || item is Button || item is Panel)
                {
                    item.BackColor = Color.Transparent;
                }
            }
            tiemzou();
        }
        public event EventHandler tjtx;//刷新主界面的头像

        private void frm_SheZhi_Load(object sender, EventArgs e)
        {
            Frm_Login f = new Frm_Login();

            Icon = f.Icon;
            foreach (Control i in Controls)
            {
                i.Anchor = AnchorStyles.None;
            }
            if (love.denglu_IsSelldeOrBuyde == "卖")
            {
                string    sql1 = string.Format("select * from sellde where username ='******'", love.denglu_username == string.Empty ? "a" : love.denglu_username);
                DataTable d    = sqlHelper.ExecutedataTable(sql1, CommandType.Text, null);
                //	pwd	nicheng	zhenname	photo	sex	fahuodizhi	yue	sfzh			mibaodan	zhucetime
                txt_Ni.Text       = d.Rows[0]["nicheng"].ToString();
                txt_telephon.Text = d.Rows[0]["telephone"].ToString();

                #region 获取发货地址
                string fhd = d.Rows[0]["fahuodizhi"].ToString();                                               //获得发货地址的字符串

                string sheng = fhd.Substring(0, fhd.IndexOf(" ")).Trim();                                      //从发货地址的字符串中取得省位
                cmd_Sheng.Text = sheng;                                                                        //把获得的省给commbox赋值

                string shi = fhd.Substring(fhd.IndexOf(sheng) + sheng.Length, fhd.IndexOf(" ") + 1).Trim();    //从发货地址的字符串中取得市位
                cmd_Shi.Text = shi;                                                                            //上面巧用sheng,取得它的字符串的索引位,然后索引数加上它本身的长度来作为截取字符串的起点,直到下一个空格中的数就是省位,下面的原理一样

                string xiangzheng = fhd.Substring(fhd.IndexOf(shi) + shi.Length, fhd.IndexOf(" ") + 1).Trim(); //从发货地址的字符串中取得乡镇位
                cmd_Xiang.Text = xiangzheng;

                string xiangxidizhi = fhd.Substring(fhd.IndexOf(xiangzheng) + xiangzheng.Length).Trim();//从发货地址的字符串中取得最后的详细位
                txt_xiangxidizhi.Text = xiangxidizhi;
                #endregion
                lab_yuanmibaowenti.Text = d.Rows[0]["mibaowt"].ToString();
                //新密保保留

                string pic = string.Format("select photo from sellde where username ='******'", love.denglu_username == string.Empty ? "a" : love.denglu_username);
                sqlHelper.imagechu(pic, pic_touxiang);

                foreach (Control item in Controls)
                {
                    if (item is Label)
                    {
                        item.BackColor = Color.Transparent;
                    }
                }
            }
            else//说明是买家
            {
                string    sql1 = string.Format("select * from buyde where username ='******'", love.denglu_username == string.Empty ? "b" : love.denglu_username);
                DataTable d    = sqlHelper.ExecutedataTable(sql1, CommandType.Text, null);
                //	pwd	nicheng	zhenname	photo	sex	fahuodizhi	yue	sfzh			mibaodan	zhucetime
                txt_Ni.Text       = d.Rows[0]["nicheng"].ToString();
                txt_telephon.Text = d.Rows[0]["telephone"].ToString();

                #region 获取发货地址
                string shd = d.Rows[0]["shouhuodizhi"].ToString();                                             //获得发货地址的字符串

                string sheng = shd.Substring(0, shd.IndexOf(" ")).Trim();                                      //从发货地址的字符串中取得省位
                cmd_Sheng.Text = sheng;                                                                        //把获得的省给commbox赋值

                string shi = shd.Substring(shd.IndexOf(sheng) + sheng.Length, shd.IndexOf(" ") + 1).Trim();    //从发货地址的字符串中取得市位
                cmd_Shi.Text = shi;                                                                            //上面巧用sheng,取得它的字符串的索引位,然后索引数加上它本身的长度来作为截取字符串的起点,直到下一个空格中的数就是省位,下面的原理一样

                string xiangzheng = shd.Substring(shd.IndexOf(shi) + shi.Length, shd.IndexOf(" ") + 1).Trim(); //从发货地址的字符串中取得乡镇位
                cmd_Xiang.Text = xiangzheng;

                string xiangxidizhi = shd.Substring(shd.IndexOf(xiangzheng) + xiangzheng.Length).Trim();//从发货地址的字符串中取得最后的详细位
                txt_xiangxidizhi.Text = xiangxidizhi;
                #endregion
                lab_yuanmibaowenti.Text = d.Rows[0]["mibaowt"].ToString();
                //新密保保留

                string pic = string.Format("select photo from buyde where username ='******'", love.denglu_username == string.Empty ? "b" : love.denglu_username);
                sqlHelper.imagechu(pic, pic_touxiang);

                foreach (Control item in Controls)
                {
                    if (item is Label)
                    {
                        item.BackColor = Color.Transparent;
                    }
                }
            }
        }
示例#17
0
        private void frm_buydeZhifu_Load(object sender, EventArgs e)
        {
            Frm_Login f = new Frm_Login();

            Icon = f.Icon;
            foreach (Control i in Controls)
            {
                i.Anchor = AnchorStyles.None;
            }
            //在Frm_Login窗体里给 id 登陆名下了一个定义  代码love.buyde_id = txt_username.Text;
            //string id = love.buyde_id;//获取到买家的账号id
            //string sql = string.Format("select b.username,c.name,c.shoujia,c.kuadi,b.zhenname,b.telephone,b.shouhuodizhi,b.yue,c.shoujia,c.picda  from commodity c,buyde b where comid={0} and b.username='******'",
            //    love.goumaiid == string.Empty ? "1" : love.goumaiid, love.denglu_username == string.Empty ? "b" : love.denglu_username);//这里的商品id记得到时候需要调

            string sql = string.Format("select b.username,c.name,c.shoujia,c.kuadi,b.zhenname,b.telephone,b.shouhuodizhi,b.yue,c.shoujia,c.picda  from commodity c,buyde b where comid={0}",
                                       love.goumaiid == string.Empty ? "1" : love.goumaiid);//这里的商品id记得到时候需要调

            DataTable d = sqlHelper.ExecutedataTable(sql, CommandType.Text, null);

            lab_Buyde_id.Text    = d.Rows[0]["username"].ToString();//第一行的 列表名为“username”下面的内容
            lab_comname.Text     = d.Rows[0]["name"].ToString();
            lab_shoujia.Text     = d.Rows[0]["shoujia"].ToString();
            lab_kuaidi.Text      = d.Rows[0]["kuadi"].ToString();
            txt_ZFbuydeName.Text = d.Rows[0]["zhenname"].ToString();
            txt_telephone.Text   = d.Rows[0]["telephone"].ToString();
            txt_ZFShouhuoDZ.Text = d.Rows[0]["shouhuodizhi"].ToString();
            lab_buydeyue.Text    = d.Rows[0]["yue"].ToString();
            lab_zfje.Text        = d.Rows[0]["shoujia"].ToString();
            sqlHelper.imagechu(d.Rows[0]["picda"], pic_com);

            //Point point = new Point(lab_lo_or_location.Location.X, lab_lo_or_location.Location.Y + 45);//用收货地址下面的位置
            Point point = new Point(lab_comname.Right + 30, lab_comname.Top);//用收货地址下面的位置
            Label ll    = new Label();

            if (love.goumaicolor != string.Empty)
            {
                ll.Location = point;
                Controls.Add(ll);
                ll.Width = 200;
                ll.Text  = "所选颜色分类:" + love.goumaicolor + "色";
            }
            if (love.goumaiorther != string.Empty)
            {
                if (ll.Text.Length == 0)//说明没有颜色
                {
                    ll.Location = point;
                    Controls.Add(ll);
                    ll.Width = 200;
                    ll.Text  = "你选择的商品分类为:\" " + love.goumaiorther + " \"";
                }
                else
                {
                    ll.Text += "、" + love.goumaiorther;
                }
            }
            else
            {
                Controls.Remove(ll);
            }
            ll.Anchor         = AnchorStyles.None;
            love.goumaicolor  = string.Empty; //用完就清空
            love.goumaiorther = string.Empty; //用完就清空

            love.meihua(this);

            lab_tip.Text = string.Format("亲爱的 {0} ╭(╯3╰)╮,最近有不法分子做假软件骗钱,注意保管你的财务。^-^", love.denglu_username == string.Empty ? "b" : love.denglu_username);

            tiemzou();
        }
        private void Form1_Load(object sender, EventArgs e) //窗体诞生的时候
        {
            AcceptButton = btn_addcom;                      //默认enter为添加商品
            foreach (Control i in Controls)
            {
                i.Anchor = AnchorStyles.None;
            }
            Frm_Login f = new Frm_Login();

            Icon = f.Icon;

            txt_xiangxi_forecolor = txt_xiangxi.ForeColor;
            txt_orther.ForeColor  = txt_xiangxi_forecolor;

            //ckb_isorcolor.Checked = true;
            //ckb_isororther.Checked = true;

            //测试期间先填入图片,以减少测试期间的选择图片的时间
            //pic_daico.Image = Image.FromFile(Application.StartupPath + "\\image\\陈奕迅_陪你度过漫长岁月_4.jpg");
            //pic_xiao1.Image = pic_daico.Image;
            //pic_xiao2.Image = pic_daico.Image;
            //pic_xiao3.Image = pic_daico.Image;


            //为combox物流公司填入信息
            string[] wuliu =
            {
                "请选择",     "顺丰",   "中通",    "圆通",   "申通",        "韵达",  "汇通",   "天天",   "中国邮政",  "EMS",  "宅急送",  "德邦物流",  "国通快递", "佳吉快运", "中铁快运", "速尔快递",
                "中邮物流",    "能达速递", "全峰快递",  "快捷速递", "联邦快递FedEx", "DHL", "优速快递", "天地华宇", "全日通快递", "信丰物流", "新邦物流", "UPS快递",
                "TNT国际快递", "盛辉物流", "中外运全一", "佳怡物流", "飞康达物流",     "联昊通快递"
            };
            cmb_wuliugongsi.Items.AddRange(wuliu);
            cmb_wuliugongsi.FlatStyle     = FlatStyle.Popup;
            cmb_wuliugongsi.DropDownStyle = ComboBoxStyle.DropDownList;
            cmb_wuliugongsi.SelectedIndex = 0;

            if (ckb_isororther.Checked == false)
            {
                list_orther.Items.Clear();
                list_orther.ForeColor = txt_xiangxi_forecolor;

                list_orther.Font = new Font(list_orther.Font.FontFamily, 15);

                string[]      sx  = { "没", "有", "任", "何", "属", "性" };
                List <string> lsx = new List <string>();
                lsx.AddRange(sx);

                foreach (var item in lsx)
                {
                    list_orther.ItemHeight = 255;
                    list_orther.Items.Add(""); //提升行距
                    list_orther.Items.Add("    " + item);
                    list_orther.Items.Add(""); //提升行距
                }
            }

            foreach (Control item in Controls)
            {
                if (item is Label || item is CheckBox || item is PictureBox || item is GroupBox || item is Button || item is Panel)
                {
                    item.BackColor = Color.Transparent;
                }
                //if (item is PictureBox)
                //{
                //    PictureBox bbb = (PictureBox)item;
                //    bbb.BorderStyle = BorderStyle.None;
                //}
            }
        }