Beispiel #1
0
        private void txtFind_OnTextChange(object sender, EventArgs e)
        {
            string msg    = (sender as BunifuTextbox).text;
            string filter = string.Format("ad_user like '%{0}%' or isAd = {0}", msg);

            HandleGrView.FilterDataTable(viewUser.DataSource as DataTable, filter);
        }
Beispiel #2
0
        private void setDataTable()
        {
            string query = string.Format("select * from admin_athu where isAd = 0 or ad_user ='******' order by isAd asc", FormLogin.username);

            viewUser.DataSource = HandleGrView.GetDataSource(query);

            viewUser.Columns["ad_password"].Visible    = false;
            viewUser.Columns["Images"].Visible         = false;
            viewUser.Columns["ad_user"].HeaderText     = "Username";
            viewUser.Columns["isAd"].HeaderText        = "Có phải admin";
            viewUser.Columns["FullName"].HeaderText    = "Tên";
            viewUser.Columns["Live"].HeaderText        = "Nơi Sống";
            viewUser.Columns["DateOfBirth"].HeaderText = "Ngày Sinh";
            viewUser.Columns["PhoneNumber"].HeaderText = "Số Điện Thoại";
        }