예제 #1
0
        private void btnTimKiem_Click(object sender, EventArgs e)
        {
            DanhSachKhachTroDataContext db = new DanhSachKhachTroDataContext();

            dataGridView1.DataSource = db.KHACHTROs.Where(p => p.HoTen.Equals(txtTimkiem.Text));
        }
예제 #2
0
        void Xemkhachtro()
        {
            DanhSachKhachTroDataContext dskt = new DanhSachKhachTroDataContext();

            dataGridView1.DataSource = dskt.KHACHTROs.Select(d => d);
        }