private void Button1_Click(object sender, System.EventArgs e)
{
StringWriter sw = new StringWriter ();
Server.Execute("index.aspx",sw);
string content = sw.ToString();
//Response.Write(content);
//Response.Flush();
try
{
System.IO.StreamWriter swr = new System.IO.StreamWriter(Server.MapPath("index.htm"),false,System.Text.Encoding.Default);
swr.Write(content);
swr.Close();
sw.Close();
Response.Write("OK");
}
catch
{
}
}
{
StringWriter sw = new StringWriter ();
Server.Execute("index.aspx",sw);
string content = sw.ToString();
//Response.Write(content);
//Response.Flush();
try
{
System.IO.StreamWriter swr = new System.IO.StreamWriter(Server.MapPath("index.htm"),false,System.Text.Encoding.Default);
swr.Write(content);
swr.Close();
sw.Close();
Response.Write("OK");
}
catch
{
}
}