protected void btnSave_Click(Object Sender, EventArgs e) { if (lblId.Text == "") { oForecast.AddAffects(intQuestion, intAffected, Int32.Parse(ddlState.SelectedItem.Value)); } else { oForecast.UpdateAffects(Int32.Parse(lblId.Text), Int32.Parse(ddlState.SelectedItem.Value)); } Reload(); }