protected void ImgExpExcel_Click(object sender, EventArgs e) { int rowcount = ucCustomPagerItems.isCountRecord; string searchText = null; if (txtfilter.Text.Trim() != "") { searchText = txtfilter.Text.Trim(); } DataTable dt = objBLLAppType.Get_Approval_Type(searchText); string[] HeaderCaptions = { "Approval type", "Amount Applicable" }; string[] DataColumnsName = { "TYPE_VALUE", "AMOUNT_APPLICABLE" }; GridViewExportUtil.ShowExcel(dt, HeaderCaptions, DataColumnsName, "ApprovalType", "Approval Type", ""); }
public void Load_ApprovalType() { BLL_Infra_Approval_Type objBLLAppType = new BLL_Infra_Approval_Type(); DataTable dt = objBLLAppType.Get_Approval_Type(null); ddlType.DataSource = dt; ddlType.DataTextField = "TYPE_VALUE"; ddlType.DataValueField = "TYPE_KEY"; ddlType.DataBind(); ddlType.Items.Insert(0, new ListItem("-Select-", "0")); }