protected void Page_Load(object sender, EventArgs e) { if (!Page.IsPostBack) { pagenum = Request.QueryString["page"]; pid = Request.QueryString["pid"]; BindSchoolsList(); if (string.IsNullOrEmpty(pid)) { Response.Redirect("~/Default.aspx"); } else { ProgramsController sysmgr = new ProgramsController(); Programs info = null; info = sysmgr.FindByPKID(int.Parse(pid)); if (info == null) { ShowMessage("Record is not in Database.", "alert alert-info"); Clear(sender, e); } else { ProgramID.Text = info.ProgramID.ToString(); ProgramName.Text = info.ProgramName; DiplomaName.Text = info.DiplomaName; //NULL in Database SchoolCode.SelectedValue = info.SchoolCode; Tuition.Text = string.Format("{0:0.00}", info.Tuition.ToString()); InternationalTuition.Text = string.Format("{0:0.00}", info.InternationalTuition.ToString()); } } } }