XML file can not be directly opened. you have to write following code to save on local system.
<asp:linkbutton id="lb_DownloadXML" runat="server" text="Download file" onclick="lb_DownloadXML_Click" xmlns:asp="#unknown"></asp:linkbutton>
protected void lb_DownloadXML_Click(object sender, EventArgs e)
{
string strFullPath = Server.MapPath("~/temp.xml");
string strContents = null;
System.IO.StreamReader objReader = default(System.IO.StreamReader);
objReader = new System.IO.StreamReader(strFullPath);
strContents = objReader.ReadToEnd();
objReader.Close();
string attachment = "attachment; filename=test.xml";
Response.ClearContent();
Response.ContentType = "application/xml";
Response.AddHeader("content-disposition", attachment);
Response.Write(strContents);
Response.End();
}
Hope this may help you...