Exemple #1
0
 protected void GridView_units_PageIndexChanging(object sender, GridViewPageEventArgs e)
 {
     try
     {
         BindData();
         GridView_units.PageIndex = e.NewPageIndex;
         GridView_units.DataBind();
         NotifyMsg("", "none", "");
     }
     catch (Exception ex)
     {
         con.ExcutehostProc(Com_username, "Log_Issues", new string[] { "msg", "details" }, ex.Message, "Err-Item-GridView_units_PageIndexChanging");
     }
 }
Exemple #2
0
    private void BindData()
    {
        try
        {
            DataTable dtu = con.SelecthostProc(Com_username, "Unit_Select", null, null);
            GridView_units.DataSource = dtu;
            GridView_units.DataBind();


            item_unit.DataSource     = dtu;
            item_unit.DataTextField  = "Unit_NameEn";
            item_unit.DataValueField = "Unit_ID";
            item_unit.DataBind();

            item_unit.Items.Insert(0, "");
        }
        catch (Exception ex)
        {
            con.ExcutehostProc(Com_username, "Log_Issues", new string[] { "msg", "details" }, ex.Message, "Err-Item-BindData");
        }
    }