protected void Page_Load(object sender, EventArgs e) { if (!IsPostBack) { txtFromDate.Text = GeneralUtility.ConvertDisplayDateStringFormat(System.DateTime.Now); txtToDate.Text = GeneralUtility.ConvertDisplayDateStringFormat(System.DateTime.Now); var Probes = new Probes(); var result = Probes.FindAllBranch(); ddlCenterName.Items.Insert(0, "All"); for (int i = 0; i < result.Count; i++) { ddlCenterName.Items.Insert(i + 1, new ListItem(result[i].BranchName, result[i].BranchCode)); } #region "Not Used" //var Probes = new Probes(); //var result = Probes.Finds().Select(x => x.Center).Distinct().ToList(); //ddlCenterName.Items.Insert(0, "All"); //for (int i = 0; i < result.Count; i++) //{ // ddlCenterName.Items.Insert(i + 1, new ListItem(result[i], result[i])); //} #endregion } }
protected void Page_Load(object sender, EventArgs e) { if (!IsPostBack) { //txtImportDate.Text = GeneralUtility.ConvertDisplayDateStringFormat(System.DateTime.Now); globalCenterName = string.Empty; var Probes = new Probes(); var result = Probes.FindAllBranch(); for (int i = 0; i < result.Count; i++) { ddlCenterName.Items.Insert(i, new ListItem(result[i].BranchName, result[i].BranchCode)); } } }
protected void Page_Load(object sender, EventArgs e) { if (!IsPostBack) { var Probes = new Probes(); var result = Probes.FindAllBranch(); for (int i = 0; i < result.Count; i++) { ddlCenterName.Items.Insert(i, new ListItem(result[i].BranchName, result[i].BranchCode)); } var date1 = GeneralUtility.ConvertDisplayDateStringFormat(System.DateTime.Now); date = GeneralUtility.ConvertSystemDateStringFormat(txtImportDate.Text); txtImportDate.Text = date1.Substring(3, 7).ToString(); } }
protected void Page_Load(object sender, EventArgs e) { if (!IsPostBack) { //BindQAT(); var Probes = new Probes(); var result = Probes.FindAllBranch(); for (int i = 0; i < result.Count; i++) { ddlCenterName.Items.Insert(i, new ListItem(result[i].BranchName, result[i].BranchCode)); } ddlCenterName_SelectedIndexChanged(sender, e); if (btnSubmit.Text == "Search") { BindGrid(); } } }