コード例 #1
0
 protected void Button2_Click(object sender, EventArgs e)
 {
     Bll.CategoryTable Bct = new Bll.CategoryTable();
     this.GridView1.DataSource   = Bct.select("BookCategory like '%" + txtCategory.Text + "%'");
     this.GridView1.DataKeyNames = new string[] { "ID" };
     this.GridView1.DataBind();
 }
コード例 #2
0
 public void bind()
 {
     Bll.CategoryTable Bct = new Bll.CategoryTable();
     this.GridView1.DataSource   = Bct.select("");
     this.GridView1.DataKeyNames = new string[] { "ID" };
     this.GridView1.DataBind();
 }