protected void btnAdd_Click(Object Sender, EventArgs e) { if (txtCost.Text.Trim() == "") { txtCost.Text = "0"; } if (intID == 0) { oForecast.AddAcquisition(intModel, Int32.Parse(ddlLineItem.SelectedItem.Value), double.Parse(txtCost.Text), (chkProduction.Checked ? 1 : 0), (chkEnabled.Checked ? 1 : 0)); } else { oForecast.UpdateAcquisition(intID, Int32.Parse(ddlLineItem.SelectedItem.Value), double.Parse(txtCost.Text), (chkProduction.Checked ? 1 : 0), (chkEnabled.Checked ? 1 : 0)); } Response.Redirect(Request.Path + "?mid=" + intModel.ToString()); }