{
string image_name = "";
SqlCommand cmd1 = new SqlCommand("Select Image from Slider_Data where Section=@Section", con);
cmd1.Parameters.AddWithValue("@Section", ddlsection.SelectedValue);
con.Open();
SqlDataReader dr = cmd1.ExecuteReader();
if (dr.Read())
{
image_name = dr["Image"].ToString();
}
cmd1.Parameters.AddWithValue("@Image", image_name);
con.Close();
}
cmd.Parameters.AddWithValue("@Description",CKEditorControl.Text);
con.Open();
int i = cmd.ExecuteNonQuery();
if (i == 1)
{
Response.Write("<script>('Updated Successfully')</script>");
}
con.Close();
}
}
catch(Exception ex)
{
Response.Write(ex.Message);
}