Ejemplo n.º 1
0
    public string SinhMaNhanVien()
    {
        var ma = (DanhSachNhanVien.Max(nv => nv.STT) + 1).ToString();

        while (ma.Length < 5)
        {
            ma = "0" + ma;
        }
        return(string.Format(@"NV{0}", ma));
    }
Ejemplo n.º 2
0
        private void btnDSNHANVIEN_ItemClick(object sender, DevExpress.XtraBars.ItemClickEventArgs e) // form report danh sach nhan vien ben
        {
            Form frm = this.CheckExists(typeof(DanhSachNhanVien));

            if (frm != null)
            {
                frm.Activate();
            }
            else
            {
                DanhSachNhanVien f = new DanhSachNhanVien()
                {
                    MdiParent = this, Text = "Danh sách nhân viên công ty"
                };
                f.Show();
            }
        }
        private void buttonItem5_Click(object sender, EventArgs e)
        {
            DanhSachNhanVien dsnv = new DanhSachNhanVien();

            dsnv.ShowDialog();
        }