コード例 #1
0
    public void deleteLV(string query)
    {
        if (con.State != ConnectionState.Open)
        {
            con.Open();
        }
        SqlDataAdapter da = new SqlDataAdapter(query, con);

        DataTable dt = new DataTable();

        da.Fill(dt);
        DeleteBookLV.DataSource = dt;
        DeleteBookLV.DataBind();
        con.Close();
    }
コード例 #2
0
 protected void DeleteBookLV_PagePropertiesChanging(object sender, PagePropertiesChangingEventArgs e)
 {
     (DeleteBookLV.FindControl("DataPager1") as DataPager).SetPageProperties(e.StartRowIndex, e.MaximumRows, false);
     deleteLV("select * from Add_Book where isActive ='0' ");
 }