protected void ddlUpazilla_SelectedIndexChanged(object sender, EventArgs e)
 {
     ddlUnion.Items.Clear();
     if (ddlUpazilla.SelectedIndex > 0)
     {
         List <ALRD_UnionInfoEntity> union = ALRD_UnionInfoService.GetService().GetAll(new ALRD_UnionInfoEntity {
             UpazilaID = long.Parse(ddlUpazilla.SelectedValue)
         }).ToList();
         LoadComboRef(ref ddlUnion, union, CommonFunctions.GetPropertyName((ALRD_UnionInfoEntity x) => x.DESCRIPT), CommonFunctions.GetPropertyName((ALRD_UnionInfoEntity x) => x.COMPID));
     }
 }
Beispiel #2
0
        private void LoadData()
        {
            IList <ALRD_UnionInfoEntity> itemList = new List <ALRD_UnionInfoEntity>();

            try
            {
                LocalDataStore = ALRD_UnionInfoService.GetService().GetAll(new ALRD_UnionInfoEntity()).ToList();
                if (LocalDataStore != null && LocalDataStore.Count > 0)
                {
                    this.lsv_SetupPage.DataSource = LocalDataStore;
                }
                else
                {
                    this.lsv_SetupPage.EditIndex          = -1;
                    this.lsv_SetupPage.InsertItemPosition = InsertItemPosition.FirstItem;
                    this.lsv_SetupPage.DataSource         = new List <ALRD_UnionInfoEntity>();
                }
                this.lsv_SetupPage.DataBind();
            }
            catch (Exception ex)
            {
                throw ex;
            }
        }