using System;
using System.Data;
using System.Configuration;
using System.Web;
using System.Web.Security;
using System.Web.UI;
using System.Web.UI.WebControls;
using System.Web.UI.WebControls.WebParts;
using System.Web.UI.HtmlControls;

/// <summary>
/// BlogerDel 的摘要说明
/// </summary>
public class BlogerDel
{
    private DataSet3 ds = new DataSet3();
    private DataSet3.BlogerCountDataTable dt = new DataSet3.BlogerCountDataTable();
    private DataSet3TableAdapters.BlogerCountTableAdapter da = new DataSet3TableAdapters.BlogerCountTableAdapter();

    public BlogerDel()
    {
        //
        // TODO: 在此处添加构造函数逻辑
        //
    }
    public void ForDel(int id)
    {
        this.da.Fill(this.dt);
        int Id = id;
        for (int i = 0; i < this.dt.Rows.Count; i++)
        {
            int s = int.Parse(this.dt.Rows[i]["college_id"].ToString());
            if (s == Id)
            {
                int temp = 0;
                temp = int.Parse(this.dt.Rows[i]["bloger_count"].ToString());
                dt.Rows[i]["bloger_count"] = temp - 1;
                break;
            }
        }
        this.da.Update(this.dt);
    }
}
