protected void Page_Load(object sender, EventArgs e)
{
Response.ContentEncoding = System.Text.Encoding.UTF8;
Response.ContentType = "text/xml";
Response.Cache.SetCacheability(HttpCacheability.NoCache);
int report_uid;
int new_state;
if (int.TryParse(Request.QueryString["report_uid"], out report_uid) == false)
{
return;
}
if (int.TryParse(Request.QueryString["state"], out new_state) == false)
new_state = 1;
using (System.Xml.XmlTextWriter writer = new System.Xml.XmlTextWriter(Response.OutputStream, System.Text.Encoding.UTF8))
{
writer.WriteStartDocument();
writer.WriteStartElement("Outputs");
DB.UpdateReportState(report_uid, new_state);
writer.WriteEndElement();
writer.WriteEndDocument();
writer.Flush();
writer.Close();
}
}