/// <summary>
    /// 绑定数据
    /// </summary>
    private void PolicyDataBind()
    {
        DataTable dt    = BG_PolicyLogic.GetAllPolicy();
        Store     store = this.gridpanel1.GetStore();

        store.DataSource = dt;
        store.DataBind();
    }
Exemplo n.º 2
0
 protected void Page_Load(object sender, EventArgs e)
 {
     if (!X.IsAjaxRequest)
     {
         DataTable dt    = BG_PolicyLogic.GetAllPolicy();
         Store     store = this.GridPanel1.GetStore();
         store.DataSource = dt;
         store.DataBind();
         //if (dt.Rows.Count > 0)
         //{
         //    string PTitle = dt.Rows[0]["PTitle"].ToString();
         //    string PContent = dt.Rows[0]["PContent"].ToString();
         //}
     }
 }
    protected void Page_Load(object sender, EventArgs e)
    {
        if (!X.IsAjaxRequest)
        {
            Kv        k  = new Kv();
            DataTable dt = BG_PolicyLogic.GetAllPolicy();
            for (int i = 0; i < 100; i++)
            {
                dt.Rows[0]["PTitle"] = k.Key + i;
                dt.Rows[0]["PTitle"] = k.Val + i;
            }

            Store store = this.GridPanel1.GetStore();
            store.DataSource = dt;
            store.DataBind();
        }
    }