public bool check_idph(string id)
 {
     DataConnect dc = new DataConnect();
     SqlParameter ma = new SqlParameter("@MaPhieuNhap", id);
     DataTable dt = dc.ExecuteQuery("select *from tblPhieuNhap where MaPhieuNhap=@MaPhieuNhap", ma);
     return dt.Rows.Count > 0;
 }
 public bool check_idNCC(string ma)
 {
     DataConnect dc = new DataConnect();
     SqlParameter id = new SqlParameter("@MaNCC", ma);
     DataTable dt = dc.ExecuteQuery("select *from tblNCC where MaNCC=@MaNCC", id);
     return dt.Rows.Count > 0;
 }
 public bool check_idMa(string id)
 {
     DataConnect dc = new DataConnect();
     SqlParameter ma = new SqlParameter("@MaHang", id);
     DataTable dt = dc.ExecuteQuery("select *from tblSanPham where MaHang=@MaHang", ma);
     return dt.Rows.Count > 0;
 }
 //kiểm tra mã khách hàng
 public bool check_IdKH(string id)
 {
     DataConnect dc = new DataConnect();
     SqlParameter ma = new SqlParameter("@MaKH", id);
     DataTable dt = dc.ExecuteQuery("select *from tblKhachHang where MaKH=@MaKH", ma);
     return dt.Rows.Count > 0;
 }
 //kiểm tra mã id có trùng không
 public bool check_IDNV(string id)
 {
     DataConnect dc = new DataConnect();
     SqlParameter ma = new SqlParameter("@MaNV", id);
     DataTable dt = dc.ExecuteQuery("select *from tblNhanVien where MaNV=@MaNV", ma);
     return dt.Rows.Count > 0;
 }
 public bool check_Muc(string muc)
 {
     DataConnect dc = new DataConnect();
     SqlParameter m = new SqlParameter("@MucUD", muc);
     DataTable dt = dc.ExecuteQuery("select *from tblUuDai where MucUD=@MucUD");
     return dt.Rows.Count > 0;
 }
        //kiểm tra mã khách hàng
        public bool check_IdKH(string id)
        {
            DataConnect  dc = new DataConnect();
            SqlParameter ma = new SqlParameter("@MaKH", id);
            DataTable    dt = dc.ExecuteQuery("select *from tblKhachHang where MaKH=@MaKH", ma);

            return(dt.Rows.Count > 0);
        }
Пример #8
0
        public bool check_Muc(string muc)
        {
            DataConnect  dc = new DataConnect();
            SqlParameter m  = new SqlParameter("@MucUD", muc);
            DataTable    dt = dc.ExecuteQuery("select *from tblUuDai where MucUD=@MucUD");

            return(dt.Rows.Count > 0);
        }
        //kiểm tra mã id có trùng không
        public bool check_IDNV(string id)
        {
            DataConnect  dc = new DataConnect();
            SqlParameter ma = new SqlParameter("@MaNV", id);
            DataTable    dt = dc.ExecuteQuery("select *from tblNhanVien where MaNV=@MaNV", ma);

            return(dt.Rows.Count > 0);
        }
Пример #10
0
        public bool check_idMa(string id)
        {
            DataConnect  dc = new DataConnect();
            SqlParameter ma = new SqlParameter("@MaHang", id);
            DataTable    dt = dc.ExecuteQuery("select *from tblSanPham where MaHang=@MaHang", ma);

            return(dt.Rows.Count > 0);
        }
        public bool check_idph(string id)
        {
            DataConnect  dc = new DataConnect();
            SqlParameter ma = new SqlParameter("@MaPhieuNhap", id);
            DataTable    dt = dc.ExecuteQuery("select *from tblPhieuNhap where MaPhieuNhap=@MaPhieuNhap", ma);

            return(dt.Rows.Count > 0);
        }
        public bool check_idNCC(string ma)
        {
            DataConnect  dc = new DataConnect();
            SqlParameter id = new SqlParameter("@MaNCC", ma);
            DataTable    dt = dc.ExecuteQuery("select *from tblNCC where MaNCC=@MaNCC", id);

            return(dt.Rows.Count > 0);
        }