S
sonny
Here's the code:
private void SaveUserXml(string user, XmlDocument doc)
{
FileStream file;
FileIOPermission perm;
XmlTextWriter writer;
string xml;
try
{
doc = new XmlDocument();
xml = Server.MapPath("/protoLogin") + "\\xml\\" + user + ".xml";
file = File.Open(xml, FileMode.Create);
writer = new XmlTextWriter(file, null);
doc.WriteTo(writer);
writer.Close();
file.Close();
}
catch (Exception ex)
{
int i = 0;
}
}
Here's the exception I get:
Any thoughts on this would be greatly appreciated.
thx...sonny
private void SaveUserXml(string user, XmlDocument doc)
{
FileStream file;
FileIOPermission perm;
XmlTextWriter writer;
string xml;
try
{
doc = new XmlDocument();
xml = Server.MapPath("/protoLogin") + "\\xml\\" + user + ".xml";
file = File.Open(xml, FileMode.Create);
writer = new XmlTextWriter(file, null);
doc.WriteTo(writer);
writer.Close();
file.Close();
}
catch (Exception ex)
{
int i = 0;
}
}
Here's the exception I get:
"Access to the path \"D:\\work\\protoLogin\\xml\\sonny.xml\" is denied."? ex.Message
Any thoughts on this would be greatly appreciated.
thx...sonny