当前位置: 首页>>代码示例>>C#>>正文


C# Common.Utilities.BindingCombobox方法代码示例

本文整理汇总了C#中Common.Utilities.BindingCombobox方法的典型用法代码示例。如果您正苦于以下问题:C# Common.Utilities.BindingCombobox方法的具体用法?C# Common.Utilities.BindingCombobox怎么用?C# Common.Utilities.BindingCombobox使用的例子?那么恭喜您, 这里精选的方法代码示例或许可以为您提供帮助。您也可以进一步了解该方法所在Common.Utilities的用法示例。


在下文中一共展示了Common.Utilities.BindingCombobox方法的6个代码示例,这些例子默认根据受欢迎程度排序。您可以为喜欢或者感觉有用的代码点赞,您的评价将有助于系统推荐出更棒的C#代码示例。

示例1: LayTenTT

 /// <summary>
 /// Lấy tên tiền tệ
 /// </summary>
 /// <param name="sender"></param>
 /// <param name="e"></param>
 private void LayTenTT()
 {
     try
     {
         cbxTiente_Tygia.Items.Clear();
         cl = new Server_Client.Client();
         this.client = cl.Connect(Luu.IP, Luu.Ports);
         Entities.KiemTraChung tt1 = new Entities.KiemTraChung();
         tt1 = new Entities.KiemTraChung("Select", "TienTe", "MaTienTe", "TenTienTe");
         clientstrem = cl.SerializeObj(this.client, "LayCombox", tt1);
         Entities.KiemTraChung[] tt = new Entities.KiemTraChung[1];
         tt = (Entities.KiemTraChung[])cl.DeserializeHepper1(clientstrem, tt);
         Common.Utilities com = new Common.Utilities();
         com.BindingCombobox(tt, cbxTiente_Tygia, "giatri", "khoachinh");
         cbxTiente_Tygia.Text = "Chọn tiền tệ";
     }
     catch
     {
         cbxTiente_Tygia.Items.Clear();
         cbxTiente_Tygia.Text = "";
     }
     client.Close();
     clientstrem.Close();
 }
开发者ID:mrk29vn,项目名称:vna-accounting,代码行数:29,代码来源:frmXuLy_DonDatHang.cs

示例2: LayNhanVien

 /// <summary>
 /// Lấy nhân viên
 /// </summary>
 /// <param name="sender"></param>
 /// <param name="e"></param>
 private void LayNhanVien()
 {
     try
     {
         cl = new Server_Client.Client();
         this.client = cl.Connect(Luu.IP, Luu.Ports);
         Entities.KiemTraChung tt1 = new Entities.KiemTraChung();
         tt1 = new Entities.KiemTraChung("Select", "NhanVien", "MaNhanVien", "TenNhanVien");
         clientstrem = cl.SerializeObj(this.client, "LayCombox", tt1);
         Entities.KiemTraChung[] tt = new Entities.KiemTraChung[1];
         tt = (Entities.KiemTraChung[])cl.DeserializeHepper1(clientstrem, tt);
         Common.Utilities com = new Common.Utilities();
         com.BindingCombobox(tt, cbxNhanvien, "giatri", "khoachinh");
         cbxNhanvien.Text = "Chọn nhân viên";
     }
     catch (Exception)
     {
         cbxNhanvien.Items.Clear();
     }
     client.Close();
     clientstrem.Close();
 }
开发者ID:mrk29vn,项目名称:vna-accounting,代码行数:27,代码来源:frmXuLy_DonDatHang.cs

示例3: LayKhoHang

 /// <summary>
 ///  Lấy Kho Hàng
 /// </summary>
 private void LayKhoHang()
 {
     try
     {
         cbxMaKho.Items.Clear();
         Entities.KiemTraChung kh = new Entities.KiemTraChung();
         cl = new Server_Client.Client();
         this.client = cl.Connect(Luu.IP, Luu.Ports);
         kh = new Entities.KiemTraChung("Select", "KhoHang", "MaKho", "TenKho");
         clientstrem = cl.SerializeObj(this.client, "LayCombox", kh);
         Entities.KiemTraChung[] ddh = new Entities.KiemTraChung[1];
         ddh = (Entities.KiemTraChung[])cl.DeserializeHepper(clientstrem, ddh);
         Common.Utilities com = new Common.Utilities();
         com.BindingCombobox(ddh, cbxMaKho, "giatri", "khoachinh");
         this.cbxMaKho.Text = "Chọn kho hàng";
     }
     catch (Exception)
     { }
     client.Close();
     clientstrem.Close();
 }
开发者ID:mrk29vn,项目名称:vna-accounting,代码行数:24,代码来源:frmXuLy_DonDatHang.cs

示例4: LayTenTT

 private void LayTenTT()
 {
     try
     {
         cbxTiente_Tygia.Items.Clear();
         cl = new Server_Client.Client();
         this.client = cl.Connect(Luu.IP, Luu.Ports);
         Entities.KiemTraChung tt1 = new Entities.KiemTraChung();
         tt1 = new Entities.KiemTraChung("Select");
         clientstrem = cl.SerializeObj(this.client, "LayThongTinTienTe", tt1);
         Entities.KiemTraChung[] tt = new Entities.KiemTraChung[1];
         tt = (Entities.KiemTraChung[])cl.DeserializeHepper1(clientstrem, tt);
         tigia = tt;
         Common.Utilities com = new Common.Utilities();
         com.BindingCombobox(tt, cbxTiente_Tygia, "giatri", "khoachinh");
         client.Close();
         clientstrem.Close();
     }
     catch (Exception ex)
     {
         string s = ex.Message.ToString();
     }
 }
开发者ID:mrk29vn,项目名称:vna-accounting,代码行数:23,代码来源:frmXuLyHangTraLai.cs

示例5: frmXuLy_DonDatHang_Load

        /// <summary>
        /// ham main
        /// </summary>
        /// <param name="sender"></param>
        /// <param name="e"></param>
        private void frmXuLy_DonDatHang_Load(object sender, EventArgs e)
        {
            try
            {
                datesv = DateServer.Date();
                Entities.HienThi_ChiTiet_DonDatHang[] row = new Entities.HienThi_ChiTiet_DonDatHang[0];
                dgvInsertOrder.DataSource = row;
                DoiTen(dgvInsertOrder);
                //doc du lieu dong
                makNgaydonhang.Text = DateServer.Date().ToString("dd/MM/yyyy"); ;
                makNgaynhapdukien.Text = DateServer.Date().ToString("dd/MM/yyyy");
                this.cbxHinhthucthanhtoan.Items.AddRange(new object[] { "Tiền mặt", "ATM" });
                cbxHinhthucthanhtoan.SelectedIndex = 0;
                this.txtTrangthaidonhang.Text = "Đang mở";
                txtPhuongthucvanchuyen.Text = "Tự vận chuyển";
                //fig cung combox
                frmXuLyDonDatHang fr = new frmXuLyDonDatHang();
                if (this.HanhDong == "Insert")
                {
                    btnTimnhacungcap.Enabled = true;
                    toolStripStatus_Them.Enabled = true;
                    toolStripStatus_Ghilai.Enabled = false;
                    Application.OpenForms[fr.Name].Text = "Thêm Mới - F4 Thêm Hàng Hóa F5 Nhập Phí Vận Chuyển F6 Sửa Hàng Hóa F7 Nhập Phí Khác";
                    txtTrangthaidonhang.ReadOnly = true;
                    getID("DonDatHang");
                    txtSodonhang.Text = makiemtra;
                    checkData();
                    toolStripStatusLabel3.Enabled = false;
                }
                //LayKhoHang();
                ///lay kho hang trong xml
                new Common.Utilities().ComboxKhoHang(cbxMaKho);

                Entities.KiemTraChung[] tt = new Entities.KiemTraChung[1];
                Entities.KiemTraChung g = new Entities.KiemTraChung();
                Common.Utilities com = new Common.Utilities();
                g.Khoachinh = Common.Utilities.User.NhanVienID;
                g.Giatri = Common.Utilities.User.TenNhanVien;
                tt[0] = g;
                com.BindingCombobox(tt, cbxNhanvien, "giatri", "khoachinh");
                //LayNhanVien();
                LayTenTT();
                txtGiatien.Text = tigia[0].Giatri2.ToString();
                cbxTiente_Tygia.SelectedIndex = 0;
                cbxTiente_Tygia.Enabled = false;
                //danh cho update
                if (this.HanhDong == "Update")
                {
                    if (this.dathang.DonDatHangID > 0)
                    {
                        btnTimnhacungcap.Enabled = false;
                        toolStripStatus_Them.Enabled = false;
                        toolStripStatus_Ghilai.Enabled = true;
                        Application.OpenForms[fr.Name].Text = "Quản lý đơn đặt hàng - Xem Chi Tiết Đơn";
                        DoDuLieu(this.dathang);
                        if (txtTrangthaidonhang.Text == "Đã thành công")
                        {
                            toolStripStatus_Ghilai.Enabled = false;
                            toolStripStatusLabel3.Enabled = false;
                            toolStripStatusLabel4.Enabled = true;
                            btnTimnhacungcap.Enabled = false;
                        }
                        if (dgvInsertOrder.RowCount <= 0)
                        {
                            txtChietkhau.Text = "0";
                            txtTienhang.Text = "0";
                            txtGiatrigiatang.Text = "0";
                            txtPhivanchuyen.Text = "0";
                            txtPhikhac.Text = "0";
                            txtTongtien.Text = "0";
                        }
                        check_loaidathang.Enabled = false;
                        TinhToan();
                    }
                    else
                    { MessageBox.Show("Không tìm thấy mã đơn đặt hàng cần sửa !"); this.Close(); }
                    toolStripStatusLabel3.Enabled = true;
                }

            }
            catch (Exception ex)
            {
                string s = ex.Message;
                if (txtSodonhang.Text == "")
                {
                    txtSodonhang.Text = makhachhang;
                }
            }
        }
开发者ID:mrk29vn,项目名称:vna-accounting,代码行数:94,代码来源:frmXuLyDonDatHang.cs

示例6: LayNhanVien

 /// <summary>
 /// Lấy nhân viên
 /// </summary>
 /// <param name="sender"></param>
 /// <param name="e"></param>
 private void LayNhanVien()
 {
     try
     {
         cl = new Server_Client.Client();
         this.tcpClient = cl.Connect(Luu.IP, Luu.Ports);
         Entities.KiemTraChung tt1 = new Entities.KiemTraChung();
         tt1 = new Entities.KiemTraChung("Select", "NhanVien", "MaNhanVien", "TenNhanVien");
         networkStream = cl.SerializeObj(this.tcpClient, "LayCombox", tt1);
         Entities.KiemTraChung[] tt = new Entities.KiemTraChung[1];
         tt = (Entities.KiemTraChung[])cl.DeserializeHepper1(networkStream, tt);
         tcpClient.Close();
         networkStream.Close();
         if (tt.Length > 0)
         {
             Common.Utilities com = new Common.Utilities();
             com.BindingCombobox(tt, cbxMaNhanVien, "giatri", "khoachinh");
         }
         else
         {
             frmXuly_NhanVien frm = new frmXuly_NhanVien();
             frm.ShowDialog();
         }
     }
     catch (Exception ex)
     {
         cbxMaNhanVien.Items.Clear();
         string s = ex.Message.ToString();
     }
 }
开发者ID:mrk29vn,项目名称:vna-accounting,代码行数:35,代码来源:frmXuLyKhoHang.cs


注:本文中的Common.Utilities.BindingCombobox方法示例由纯净天空整理自Github/MSDocs等开源代码及文档管理平台,相关代码片段筛选自各路编程大神贡献的开源项目,源码版权归原作者所有,传播和使用请参考对应项目的License;未经允许,请勿转载。